



Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!




Here we build confidence intervals. This is broken into four different types.
Building confidence intervals for a population
preliminary info: x¯ = 72.5 σ = 10.2 n = 35
σ √ n
The differences from the calculations done by hand are due to round-off error in the hand calculations.
This is imported into R using the read.table command.
data <- read.table("Excel-Heart-Rate-Data.csv",header=TRUE,sep=",")
t.test(data,con.level=.95)
There is a lot of stuff put out by the t.test function. The desired confidence interval is highlighted below. Everything in red is typed by the user. Everything in blue is output to the console.
preliminary info: pˆ =
≈ 0. 313 qˆ = 1 - ˆp = 0.687 n = 1512
√ p ˆqˆ n
√ (.313)(.687) 1512
The differences from the calculations done by hand are due to round-off error in the hand calculations.