Second assignment for the R programming course in Coursera.