plot3.R (assignment 1)