R code coursera Data Science