PROBABILITY & STATISTICS · INTERVIEW QUESTION
What is the Law of Large Numbers? How does it relate to ML?
🟢 beginner · Probability Theory
Hint: Think about sample averages converging to expected values as sample size grows.
Answer
The Law of Large Numbers (LLN) states that as sample size n → ∞, the sample mean converges to the true expected value: X̄_n → E[X]. Weak LLN: convergence in probability. Strong LLN: almost sure convergence. ML relevance:
- Justifies using empirical risk minimization (average loss on training data) as a proxy for true risk
- Explains why larger training sets lead to better estimates
- Underlies Monte Carlo methods (MCMC, MC dropout)
- SGD works because mini-batch gradients approximate true gradient
- More representative independent observations can improve estimation; increasing folds on the same dataset does not guarantee a more stable cross-validation estimate.
Caveat: convergence rate matters — CLT tells us the error is , so 4x data only halves the error.
Related questions
- Explain Bayes' theorem and give an ML application.
- Explain the Central Limit Theorem and its assumptions. Why is it important in data science?
- What are conjugate priors? Give examples in Bayesian ML.
- Explain conditional probability and independence. How are they used in Naive Bayes?
- What is the difference between Type I and Type II errors? How do they relate to precision and recall?