# One mean, small sample t test. # Example is mercury concentrations in a lake (mg/m^3). mu0=1.2 # Baseline before mercury spill. alpha=.05 # Test significance level. x=c(1.60,1.77,1.61,1.08,1.07,1.79,1.34,1.07,1.45,1.59,1.43, 2.07,1.16,.85,2.11) # Measurements after spill. t.test(x,mu=mu0,conf.level=(1-alpha)) boxplot(x) abline(h=mu0,lty=2)