Module #9 - T-Test for Indpendent Samples


This week's topics covered running an independent samples t-test and interpreting using R.




Question # 1 : Find your two sample means.

  > x <- c(9,8,3,8,10)
  > y <- c(3,1,2,6,4,3,6)
  > tTest <- t.test(x,y)
  > tTest$estimate
  mean of x mean of y
   7.600000  3.571429
          




Question # 2 : Find the degrees of freedom(s).


  > tTest$parameter
        df
  6.768656
          



Question # 3 : Find t-test statistic score (s).


  > tTest$statistic
         t
  2.865148
          



Question # 4 : Find the P value(s).


  > tTest$p.value
  [1] 0.02505219
          



Question # 5 : Assume you had chosen an alpha value of .05., Would this result have been statistically significant?


  Yes. The p-value is <= 0.05.
          



Question # 6 : What critical value would your obtained t-test value have to exceed to be significant at the .01 level (assume a two-tailed test)?


  > z <- qnorm(0.99 + (0.01 / 2))
  > p <- pnorm(z)
  > z
  [1] 2.575829
  > p
  [1] 0.995
  For the t-test to exceed the significance
  value of 0.01, z must be 2.576 or p must
  be 0.995