Part
III: One & Two Sample Parametric Tests |
| | Overview
| Two Sample
z Test | Two Sample t Test | | Matched t Test | Assumptions | |
Two sample tests are what
we call tests of independence rather than goodness of fit
tests. We are testing to see whether or not 2 variables
are "related" or "dependent". Thus,
the Ho takes the general form Ho: x and y are
independent. With the 2 sample t and z, the x variable is
nominal scale of measurement and dichotomous (takes on
only 1 of 2 possible values). The y variable is treated
as continuous (can take on a whole range of values on a
continuum). For example, 2 groups each receive a
different teaching method, and their final exam scores
are compared.
Ho: x and y are independent. There is an important distinction to be made here. Sometimes people make the mistake of thinking that since there are 2 groups and 2 variables, group 1 must be x and group 2 must be y. This is incorrect, not to mention impossible. Instead, note that the independent variable, x has 2 levels (i.e. it is dichotomous). So the 2 groups are the 2 levels of the independent variable x. They are the 2 values that x can take on. We say then that the variable x refers to group membership. In addition to being placed in a group, all the subjects are measured on a second variable y, that is interval (in our case, exam scores). The logic is this: if the 2 groups (x1 and x2) do not differ in average exam scores (y), then we conclude that there is no relationship between group membership (teaching method) and final exam scores (i.e. no relationship between x and y). Just as in probability, we would say that knowing the value of x (x1 or x2) gives us no information on y (since y is no different for x1 or x2. In other words, the mean score on y in the population for group 1 does not differ from the mean score on y in group 2. (Note that this is the same as saying the the difference between them is zero!) |
| We now want to test the
null hypothesis set above. The general form of the
formula is the same as for the one sample z test: z
equals the difference of the test statistic (the mean)
and the null hypothesis value divided by the standard
deviation of the statistic. In the case of two samples, we simply subtract the means (and divide by the standard error of the difference between means) to obtain the test statistic. Below is the full z formula:
Note how the z formula simplifies when m1 - m2 = 0 (as it does in most cases). Again, if the population standard deviations are unknown, but N is sufficiently large, you can still use this formula by substituting the sample standard deviations for the population standard deviations. |
| Again, we're testing the
null hypothesis set above. The formula for the one sample
t test even closely matches our formula for the one
sample z test. And once again, note how the formula
reduces when there is no expected difference between the
two population means:
Here, the standard error of the difference between means can be calculated directly from the data. (note the n - 1 in the denominator; this formula provides the unibiased estiamte we are looking for!)
When the sample sizes are equal, the formula for the standard error simplifies somewhat:
|
When testing for a
relationship between two variables, sometimes there is a
3rd variable, which we are not interested in at the
moment, which influences our results. In our previous
example, suppose that final exam scores are also
influenced by an individuals' IQ (not just teaching
method). If we only want to focus on the influence of
teaching method on y, we need to control for individual
differences on IQ. The matched tdf test is the statistic for doing this. There
are two possible ways to do it.
So, the null hypothesis
(Ho: x and y are independent), can also be written as:
Then, using the standard "template" for our inference test, we have:
|
||
One last note: It is
important to know the assumptions we make in using the 2
sample t-test.
When homogeneity of variance is violated, Hays suggests use of the following modified 2 group tdf for independent samples.
|