## Seminar 4. Statistical laws ##
## Law of large numbers ##
# compare distributions of samples of different sizes
sample1 <- rnorm(10, mean = 168, sd = 2)
sample1
hist(sample1, col = "tomato")
sample2 <- rnorm(100, mean = 168, sd = 2)
sample2
hist(sample2, col = "tomato")
sample3 <- rnorm(10000, mean = 168, sd = 2)
sample3
hist(sample3, col = "tomato")
# compare sample means with the population mean (168)
mean(sample1); mean(sample2); mean(sample3)
## Central limit theorem ##
# discuss later