Is this the best machine learning course?

The "mascot" for the Machine Learning course.

I recently completed the Machine Learning by Stanford University course taught by Dr. Andrew Ng, and offered through Coursera.

Previously I had taken a several courses from DataCamp (see my review here), and while I found them valuable I still didn’t feel like I understood the material to a sufficiently deep level. I gained a general understanding of the tools and techniques presented and became proficient enough to use these tools for my own projects (here, and here), but as a mathematician I don’t feel like I understand an algorithm until I can code it up myself.

After completing Dr. Ng’s course, I feel like I understand the algorithms covered and the coursework provides a foundation that gives me confidence that I can implement these algorithms myself.

Course Structure and Content

The course is designed to take 11 weeks assuming you spend 5-8 hours per week on it, but allows students to work at their own pace. The material each week is presented through a set of video lectures by Dr. Ng, along with quizzes and a programming exercise.

Dr. Ng covers the most commonly used algorithms for supervised and unsupervised machine learning tasks:

  • Linear regression
  • Logistic regression
  • Neural networks
  • Support vector machines
  • K-means clustering
  • Principal component analysis

Dr. Ng is an engaging lecturer who is able to distill the essential information into easily digested pieces. The material is presented at multiple levels providing both intuition about the algorithm and the technical details behind it.

The lectures are complemented by programming exercises. Here again the essential components of each algorithm are the focus of the assignment. For example, in the linear regression exercise the students write code to compute the cost function, and a single step in the gradient descent loop. The loop structure is provided, as are a number of test cases to allow the student to verify their solution is correct. All the assignments are done in Matlab or Octave which reduces the level of programming skill required while still requiring an understanding of the math involved in each algorithm. This isn’t a coding course and much of the tedious work is done for the students. At the same time the full code is provided to the students and can be examined by those so inclined.

More than just algorithms

Week 6 in the syllabus is called “Advice for Applying Machine Learning,” and I found this to be one of the most beneficial topics. Following my earlier courses, I was able to use any number of machine learning algorithms (whether I really understood them or not) because I knew which library to load, and the syntax to train the model. But I didn’t know how to deal with cases that weren’t so simple (see here). My approach in these cases was to go with my gut feeling and hope for the best.

In the week 6 lectures, Dr. Ng presents best practices for applying machine learning, and discusses diagnostic tools (eg. error metrics, learning curves) that can help highlight reasons why the algorithm may be under-performing. Armed with these new skills, I’m going back to my previous problem to see what can be done.

Best course ever?

This course came highly recommended by a number of data scientists who I respect, and it was certainly a valuable course to take. I’m happy that I now understand the algorithms covered in this course at the deep level I was looking for.

I can’t answer this question based on my own experience, as I haven’t taken every other machine learning course that is out there. However, thanks to this course, I could build a collaborative filtering algorithm and recommender system to help answer this question.

In all seriousness, I found this course to be incredibly helpful, and would recommend it to anyone who is interested in machine learning.

Is DataCamp worth the money?

I recently left my job as a software developer to focus on transitioning into a data science role (see this post). As the first step of my transition, I am working through the courses offered by DataCamp.

DataCamp offers a range of courses in Python and R in topics including: data importing, cleaning, manipulation, and visualization, as well as probability and statistics, machine learning, and finance. Within the last month, DataCamp has also created a number of course tracks based on specific skills or career path. These tracks are very helpful. I already had a good idea of which courses I wanted to take, but the tracks laid them out in an appropriate order and automatically started the next course in the sequence.

After about 3 weeks, I’ve completed 27 courses including the Data Scientist with R career track.

The Good:

  • At $30/month you can’t beat the price, though I don’t imagine they expect many people to complete 10 courses/week. I keep seeing reminders that paying for the full year up front works out cheaper than a monthly subscription, but after my first month, I’ll have taken all the courses I’m interested in.
  • Each course has a number of video segments, with exercises interspersed.  There is no need to install R or Python to get started, everything runs through your web browser. This makes it easy to focus on understanding the underlying concepts and not worrying that all the required packages are loaded.
  • The courses are consistently good, and I feel like I learned a lot in most of them.
  • The skill and career tracks simplify the task of choosing what to do next. When I first started I read each course description and made a list, and tried to decide the best order to take the courses in. When the career tracks came along, I was able to enroll and get through my courses in an appropriate order.

The (not so) Bad:

  • Everything is done in the browser. At the end of the course, I don’t have any working examples to refer back to. Also to simplify the exercises, each exercise builds on the last. I have seldom seen all the code for one task collected together on the screen.
  • The DataCamp platform provides excellent feedback, including guidance matching the errors found in your code. The drawback is that you must code the exercise in exactly the same way the course creator did. After taking some of the more advanced programming courses, I was frustrated at the way some exercises were presented knowing that there was a better way to do it and I was unable to practice what I had already learned.
  • Many of the exercises are reduced to “fill in the blank.” I would like to do more of the typing myself as I find this helps me remember what I’ve learnt better.

At this point, I’m very happy with my experience. While I don’t think I could consider myself a Data Scientist, I’ve gotten an introduction to many topics and have at least a vague sense of how to start a project of my own. Other people might disagree and feel completely qualified to call themselves data scientists after completing the career track, but I’m a mathematician by training, and I don’t think I understand something until I know all the details about the algorithm and can implement it myself (perhaps that’s a topic for another post). None of the DataCamp courses go into this level of detail, nor do they promise to.

As with everything in life, what you get out depends on what you put in. It would be very easy to get through the DataCamp courses without learning anything. I focused on understanding the concepts since I can always look up the syntax as needed.

Have you taken any online courses? What was your experience?