Link Search Menu Expand Document

MS&E 298: Detecting Discrimination with Data

Course description 📰

What does it mean for a decision-making process to be discriminatory? How do we quantify inequality? What steps can be taken to mitigate potential bias? This hands-on course explores legal and statistical conceptions of discrimination using examples from public policy, healthcare, economics, technology, and education. Each session will consist of an interactive lecture, a live coding session where we implement techniques from the lecture, and a research paper discussion. The course also features occasional guest speakers from industry and academia.

Prerequisites: An introductory statistics course (e.g., 120, 125, 226, or CS 109) and an introductory programming course (e.g., CS 106A).

Instructor 🍎

Josh Grossman (

You can call me “Josh”!

Class schedule 🗓️


  • Wednesdays @ 3:30pm - 5:20pm PT, Mitchell Earth Sciences B67

Office Hours:

  • Wednesdays @ 5:20pm PT (after class)
  • By appointment. Email me to set up a 1-1 or group meeting!

Office hours are a great opportunity to discuss not only topics directly related to the course, but also anything else that’s on your mind.

  • For example, I welcome questions about career trajectories and research opportunities in MS&E and beyond.
  • Keep in mind that you do not need to come to office hours with an agenda. Listening in is welcomed and encouraged!
  • Finally, hanging out in office hours is a great way to set yourself up for a terrific letter of recommendation (this is true for most classes). If you don’t already, I highly recommend that you attend your instructors’ office hours in other classes from time to time.

Tentative grading 💯

  • Participation (50%)
  • Homework (50%)

You are encouraged to use ChatGPT for this class as you see fit.

Course communication 💬

We use the Ed platform to manage course questions and discussion.

Computing environment 🖥️

This course primarily uses R and Jupyter notebooks hosted on Google Colab. We extensively use the suite of tidyverse packages.

While not required, you are highly encouraged to install the Codesquire Chrome extension to improve productivity with Google Colab.

Attendance 🤚

  • Lecture attendance is mandatory, and lecture attendance is a substantial component of the participation grade. Attendance is checked with participation questions asked at random points during the lecture.

  • If you cannot attend a lecture due to an extenuating circumstance, please email Josh before lecture starts.

  • Unless otherwise noted, laptops and phones are not allowed during the lecture or paper discussion, though you are permitted to use a tablet to take handwritten notes. This article explains why we have this policy.

Access and accommodations

Stanford is committed to providing equal educational opportunities for students with disabilities.

If you experience disability, please register with the Office of Accessible Education (OAE). Professional staff will evaluate your needs, support appropriate and reasonable accommodations, and prepare an Academic Accommodation Letter for faculty. To get started, or to re-initiate services, please visit

If you already have an Academic Accommodation Letter, we invite you to share your letter with us. Academic Accommodation Letters should be shared at the earliest possible opportunity so we may partner with you and OAE to identify any barriers to access and inclusion that might be encountered in your experience of this course.

Diversity statement

It is our intent that students from all backgrounds and perspectives be well served by this course, that students’ learning needs be addressed both in and out of class, and that the diversity that students bring to this class be viewed as a resource, strength, and benefit. We aim to present materials and conduct activities in ways that are respectful of this diversity. Your suggestions are encouraged and appreciated. Please let us know if you have ideas to improve the effectiveness of the course for you personally or for other students or student groups.