Skip to content

Instantly share code, notes, and snippets.

Created February 17, 2013 18:49
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save anonymous/8f4a5f5c1adfde3b67e1 to your computer and use it in GitHub Desktop.
Save anonymous/8f4a5f5c1adfde3b67e1 to your computer and use it in GitHub Desktop.
n<-2000 #sample size
std<-1.0 #std dev
sm<-6283/n #sample mean
t.cv<-qt(0.95,n-1) #t-critical value for 95% conf interval
c(sm-(t.cv*(std/sqrt(n))), sm+(t.cv*(std/sqrt(n)))) # 3.104703 3.178297
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment