R Programming: Assignment2