[R] how to interpret t.test output

Felipe Carrillo mazatlanmexico at yahoo.com
Sat Aug 9 22:31:33 CEST 2008


# Hi all:
      #I got a vector with fish lengths(mm)
     # Can someone help me interpret the output of
     # a t.test in plain english?
     #  Based on the t.test below I can say that
     # I reject the null hypothesis because
     # the p-value is smaller than the the significance
     # level(alpha=0.05). What else can I conclude here?
    Ho = 36 mm
    Ha <> 36 mm
    fishlength <- c(35,32,37,39,42,45,37,36,35,34,40,42,41,50)
    t.test(fishlength,mu=36)
       One Sample t-test

data:  fishlength
t = 2.27, df = 13, p-value = 0.04087
alternative hypothesis: true mean is not equal to 36
95 percent confidence interval:
 36.14141 41.71573
sample estimates:
mean of x
 38.92857

    # I also would like to know how to interpret the output
    # when mu=0? Notice that the p-value from the t.test above
    #is different from this t.test. Are we trying to reject the null 
    # hypothesis here too?

    t.test(fishlength)
         One Sample t-test

data:  fishlength
t = 30.1741, df = 13, p-value = 2.017e-13
alternative hypothesis: true mean is not equal to 0
95 percent confidence interval:
 36.14141 41.71573
sample estimates:
mean of x
 38.92857

Thanks in advance for your help.


Felipe D. Carrillo
Supervisory Fishery Biologist  
Department of the Interior  
US Fish & Wildlife Service  
California, USA



More information about the R-help mailing list