Overview
This report investigates the exponential distribution using simulation and compares it to theoretical values, illustrating the Central Limit Theorem (CLT). It also analyzes the ToothGrowth dataset using exploratory data analysis and statistical inference.
knitr::opts_chunk$set(echo = TRUE, message = TRUE, warning = TRUE, fig.width = 6, fig.height = 4, dpi = 96) set.seed(123) # reproducibility
Part 1: Simulation of Exponential Distribution
We simulate averages of 40 exponential random variables with rate parameter 𝜆 = 0.2 λ=0.2.
Theoretical mean: 1 / 𝜆 = 5 1/λ=5
Theoretical variance of sample mean: ( 1 / 𝜆 ) 2 / 40 = 0.625 (1/λ) 2 /40=0.625 Sample Mean vs Theoretical Mean
Sample Variance vs Theoretical Variance Normality Check