computer science / statistics
Free University Probability and Statistics Courses for CS Students
A comparison of the free university courses in probability and statistics, with the prerequisites each syllabus actually states, what you do in each one, and which CS goal each suits. For applied data-analysis habits instead, see the data science statistics guide.
Computer science programs treat probability as a requirement for good reason: randomized algorithms, hashing analysis, machine learning, information theory and A/B testing all start from it. Free university courses exist for each of those routes, but they differ a lot in difficulty and in what they assume you already know. Choosing the wrong one costs weeks. Below, the first section maps goals to courses, the second compares the courses side by side, and the rest covers the textbooks that pair with them. If you would rather work through real tables with pandas, the applied statistics page is the better fit.
01 · PICK BY GOAL
Which course serves which CS goal
| You want | Take | Why |
|---|---|---|
| Probability for algorithms and theory classes | MIT RES.6-012 Introduction to Probability, then MIT 6.041SC | Taught by electrical engineering and computer science faculty; both have lecture videos and problem sets. |
| Probability and inference in one course, with code | MIT 18.05 | Covers probability, Bayesian inference, hypothesis tests and linear regression, and uses R for simulation. |
| Probability by lecture video, with problem practice | Harvard Statistics 110 (YouTube) | 35 videos in the playlist; its description says review materials and over 250 practice problems with detailed solutions are provided. |
| The statistics under machine learning | ISLR or ISLP, then Stanford CS229 | Statistical learning with labs in R or Python, before a math-heavy machine learning course. |
| A gentle start with no calculus | CMU Open Learning Initiative, Probability and Statistics | The only stated prerequisite is basic algebra. |
| Data science context, R code, structured by week | Harvard Data Science: Probability (edX) | Eight weeks at 1 to 2 hours per week, introductory level. |
02 · SYLLABI SIDE BY SIDE
Prerequisites and workload, as the course sites state them
| Course | Stated prerequisite | What you do |
|---|---|---|
| MIT 18.05, Spring 2022 | 18.02 Multivariable Calculus | Two 80-minute lectures and one 50-minute studio a week in the original; online you get reading, problem sets, exams with solutions and R resources. |
| MIT 6.041SC, Fall 2013 | Not stated on the course home page | Lecture videos, problem-solving videos, problem sets with solutions and exams. |
| MIT RES.6-012, Spring 2018 | Not stated on the course home page | Lecture notes and lecture videos by John Tsitsiklis and Patrick Jaillet. |
| Stanford STATS 200 (Autumn 2016 site) | Probability theory (STATS 116), multivariable calculus (MATH 52), and basic computer programming | Mathematical statistics: estimation, likelihood, tests. The assigned textbook, Rice's Mathematical Statistics and Data Analysis, is a purchase. |
| CMU OLI Probability & Statistics | Basic algebra | Interactive exercises and simulations; the Open and Free version omits scored tests and instructor tools. |
| Harvard Data Science: Probability | None listed; introductory difficulty | Audit for free on edX; a verified certificate is listed at $149. |
A pattern worth noticing: the MIT 18.05 prerequisite is multivariable calculus, and the Stanford one lists an earlier probability course (STATS 116) as well. If you have not taken calculus, start with the CMU course or Harvard's edX course and come back to the MIT sequence afterward. Where the home page lists no prerequisite, that is not the same as having none, so skim the first problem set before committing a month.
03 · THE COURSES
The course pages, with what each one gives you
- MIT OpenCourseWare 18.05: Introduction to Probability and Statistics (Spring 2022) ↗Instructors Jeremy Orloff and Jennifer French Kamrin. Lecture notes, problem sets, exams and R studio materials. The syllabus page lists the 18.02 prerequisite.ocw.mit.edu
- MIT RES.6-012: Introduction to Probability (Spring 2018) ↗Prof. John Tsitsiklis and Prof. Patrick Jaillet. A video-first course with lecture notes.ocw.mit.edu
- RES.6-012 lecture playlist (YouTube) ↗The same lectures as a single playlist, convenient on a phone.youtube.com
- MIT 6.041SC: Probabilistic Systems Analysis and Applied Probability (Fall 2013) ↗Units from basic probability through random processes, laws of large numbers and inference, with lecture videos and problem-solving videos.ocw.mit.edu
- Harvard Statistics 110: Probability (YouTube) ↗Joe Blitzstein's lectures, 35 videos in the playlist, last updated in 2018.youtube.com
- Harvard Data Science: Probability (edX) ↗Instructor Rafael Irizarry. Probability taught through a case study on the 2007 to 2008 financial crisis, with computations in R. Audit for free; verified certificate listed at $149.pll.harvard.edu
- CMU Open Learning Initiative: Probability & Statistics, Open & Free ↗Free for independent learners; designed for students with no prior statistics knowledge and with algebra as the only prerequisite.oli.cmu.edu
- Stanford STATS 200: Introduction to Statistical Inference ↗The Autumn 2016 course site, with lectures and homework. Upper-level and proof-based.web.stanford.edu
04 · TEXTBOOKS TO PAIR
Free books that match the courses
A course gives you a pace; a book gives you something to reread. Pair them rather than collecting several.
- Introduction to Probability, Statistics, and Random Processes (Pishro-Nik) ↗An open-access undergraduate textbook with chapters on simulation in MATLAB, R and Python. Pairs well with the MIT probability courses.probabilitycourse.com
- An Introduction to Statistical Learning ↗PDF downloads of the 2nd edition with R and of the Python edition (ISLP), each with labs.statlearning.com
- Think Stats, 2nd edition ↗Probability and statistics for Python programmers, available as PDF and online.greenteapress.com
- Advanced Data Analysis from an Elementary Point of View (Cosma Shalizi) ↗A draft textbook from the CMU course 36-402, for advanced undergraduates, centered on regression. The author notes it is a draft.stat.cmu.edu
- Seeing Theory ↗A visual companion for distributions and inference. The site is archived for reference.seeing-theory.brown.edu
05 · FAQ
Frequently asked questions
Which probability course should a CS student take first?
If you have taken multivariable calculus, MIT 18.05 or the MIT RES.6-012 lectures are good first choices, depending on whether you want statistics included. Without calculus, start with the CMU Open Learning Initiative course, whose only stated prerequisite is basic algebra.
Are there free statistics courses with a certificate?
Mostly not. MIT OpenCourseWare and CMU's Open and Free course give you materials but no certificate. Harvard's Data Science: Probability on edX can be audited for free, and a verified certificate is listed at $149.
Do I need calculus to learn probability for computer science?
Not for the basics. Discrete probability, expectation and many algorithm analyses need only algebra and careful thinking. Continuous distributions and the MIT 18.05 course expect multivariable calculus.
What should I learn before a machine learning course like CS229?
Stanford lists programming in Python and NumPy, probability theory, and multivariable calculus with linear algebra as prerequisites. An Introduction to Statistical Learning, whose PDFs are free, is a gentler bridge into the material.