Mathematical Statistics

Use probability to infer what a sample can tell you about a population.

Use probability to infer what a sample can tell you about a population.

Before you start. Mathematics for AI and Data Science, especially probability.

Use Python 3.12 for the examples. Install the dependencies with python -m pip install numpy scipy. Run each week as a separate script. Try the worked example on paper first, then change one assumption in the lab and explain the result. All datasets are small or generated locally.

The 12 weeks

WeekLessonWhat you’ll do
1Populations, samples, and statisticsEstimate a fixed population rate and explain why two samples disagree.
2Sampling distributions and standard errorPredict how the uncertainty of a sample mean changes with sample size.
3Law of large numbers and central limit theoremSeparate convergence of an average from the shape of its sampling distribution.
4Bias, variance, and mean squared errorChoose a variance estimator according to the error you care about.
5Likelihood and maximum likelihoodDerive a Bernoulli estimate and handle the boundary case.
6Sufficiency and Fisher informationReduce Bernoulli data to a count and measure local precision.
7Confidence intervals and coverageCompare two interval methods near a probability boundary.
8Hypothesis tests, p-values, and powerMeasure false positives and missed effects as different frequencies.
9Likelihood ratios and multiple testingCompare nested models and calculate the cost of searching many hypotheses.
10Bootstrap and permutation inferenceMatch the resampling operation to the question and unit of analysis.
11Bayesian inference with a beta priorCalculate a posterior and see how prior strength matters.
12Capstone · Analyze a randomized experimentReport an effect, quantify uncertainty, and stress-test the conclusion.

Further reading · MIT 18.650 · Statistics for Applications