This produces the following plot. Pay attention to the scale on the vertical axis.
studio3_problem_1a(1, 1000)
##
## ----------------------------------
## 1a. Frequency histogram
## See plot
This produces the following plot. Pay attention to the scale on the vertical axis.
studio3_problem_1b(1, 1000)
## -----
## Problem 1b: Density histogram
## See plot
studio3_problem_2a(1, 1000)
##
## ----------------------------------
## Problem 2a: Density histogram
## See plot
This test runs studio3_problem_2b
four times. Notice how
as n_to_average
increases, the average looks more and more
like a normal distribution.
Each call produced a plot
studio3_problem_2b(1, 4000, 4, 0.05)
##
## ----------------------------------
## -----Problem 2b: Density histogram of average
## See plot
studio3_problem_2b(1, 4000, 8, 0.05)
##
## ----------------------------------
## -----Problem 2b: Density histogram of average
## See plot
studio3_problem_2b(1, 4000, 16, 0.05)
##
## ----------------------------------
## -----Problem 2b: Density histogram of average
## See plot
studio3_problem_2b(1, 4000, 64, 0.05)
##
## ----------------------------------
## -----Problem 2b: Density histogram of average
## See plot
Wow! We just illustrated the central limit theorem.
18.05 Introduction to Probability and Statistics
Spring 2022
Authors: Jeremy Orloff and Jennifer French
For information about citing these materials or our Terms of Use, visit: https://ocw.mit.edu/terms