Assignment 1 R script