Data Science at Coursera programming assignment 1