500 likes | 577 Views
Psych 5500/6500. t Test for Two Independent Means. Fall, 2008. Cause and Effect Relationships. Does Variable X (cause/influence/affect) Variable Y ? Variable X would be the independent variable (the cause). Variable Y would be the dependent variable (the effect).
E N D
Psych 5500/6500 t Test for Two Independent Means Fall, 2008
Cause and Effect Relationships Does Variable X (cause/influence/affect) Variable Y? Variable X would be the independent variable (the cause). Variable Y would be the dependent variable (the effect).
t Test for 2 Independent Means Used to compare two independent samples, specifically we are comparing the means of the samples to see whether or not we can infer that the means of the two populations they represent are different. Usually we are testing a theory which proposes that an independent variable has made the population means different.
Example 1 Question: Does gender influence respiration rate? Design: randomly sample 20 males and 20 females from some population and measure their respiration rate while at rest.
Example 1 I.V.= D.V.= H0: μfemale= μmale (or) μfemale-μmale =0 HA: μfemale μmale (or) μfemale-μmale 0
Hypotheses Note that the hypotheses are always about populations. H0: μfemale= μmaleHA: μfemale μmale NOT about samples: We want to be able to generalize the results to the populations from which we sampled, not just to the specific participants who are in our sample.
Example 2 Question: Is maze running ability affected by the presence or absence of some specific drug? Design: Select 11 rats and randomly divide them into two groups. The rats in Group 1 are given the drug, the rats in Group 2 are not. The number of wrong turns each rat makes before reaching the end of the maze is recorded.
Example 2 I.V.= D.V.= H0: μdrug= μno_drug (or) μdrug-μno_drug = 0 HA: μdrug μno_drug (or) μdrug-μno_drug 0
Statistic The statistic upon which we will base our decision about H0 is: Challenge: if H0 is true then the two population means are equal, and we expect the two sample means to be similar, but even if H0 is true the two sample means will not exactly equal each other due to chance (i.e. the samples have random bias). So if the two sample means differ is that due to differences in the population means or due to chance?
The Solution Set up the ‘Sampling Distribution of assuming H0 is true’ and label it as such. Then: • The mean of that sampling distribution is based upon H0. • The standard deviation of that sampling distribution is estimated from the data from the two samples
Sampling Distribution (cont.) (based upon H0 being true) Computational formula for the standard error of the difference:
Standard Error of the Difference Let’s take a conceptual look at the standard deviation of the test statistic This t test assumes that both populations have the same variance, and uses this to ‘pool’ the two estimates of this population variance into one good estimate using the following formula, which weights the estimate based upon the size of each sample was.: Conceptual formula for the standard error of the difference:
Decision We ‘reject H0’. We can conclude that the two samples represent populations that have different means. We would like to then go on and state that the independent variable (drug vs. no drug) must have made the two population means different from each other, but at this point we can’t, first we have to show that there is no other reason for why the two populations might have different means. This takes us to the topic of ‘confounding variables’, which we will cover in the next lecture.
Confidence Intervals Confidence interval for the true difference between μ1 and μ2 : 95% confidence interval: 0.67 (μ1 - μ2) 5.33 If a hypothesis states a value for μ1 - μ2 that is outside of that confidence interval (e.g. H0: μ1 - μ2 = 0) then you can reject it
Reporting Results A standard way of reporting the results of t tests is to use the following format: t(df)=tobt, p=? From last example: t(9)=2.91, p=... We can use the ‘t distribution tool’ in ‘Oakley Stat Tools’ to get the exact value of p, or we can use SPSS to do the t test for us. t(9) = 2.91, p=.017
One-Tailed Tests So far the examples have involved non-directional theories (which predict the two population means will be different but don’t predict one which will be greater than the other). This is done with a 2-tail test. It is also possible to test theories which are directional (predict specifically which population mean should be greater). This is done with a 1-tail test, which will influence how we write our hypotheses, and will lead to just one rejection region in our sampling distribution.
One-tailed Tests Again, express the prediction made by the theory when you write HA, H0 is then everything else. For testing a theory which predicts that the mean of population one (drugged rats) should be greater than the mean of population two (undrugged rats): H0: μ1 μ2 (or equivalently) μ1-μ2 0 HA: μ1 > μ2 (or equivalently) μ1-μ2 > 0
one-tailed tests For testing a theory which predicts that the mean of population one (drugged rats) should be less than the mean of population two (undrugged rats): H0: μ1 μ2 (or equivalently) μ1-μ2 0 HA: μ1 < μ2 (or equivalently) μ1-μ2< 0
Null Hypothesis I have given two ways of expressing H0. H0: μdrug= μno_drug (or) μdrug - μno_drug = 0 The first way is somewhat conceptually easier, but the second has an advantage as well. I have mentioned before that the null hypothesis is usually, but not always, the hypothesis of ‘no difference’. Let me now give an example where that wouldn’t be true…
Let us say that the difference in population means between rats on the drug and those not on the drug has been previously established as equaling 1.5. In this experiment, however, we will have the rats swim through the maze and we are testing a theory which predicts that the difference between the two groups should be influenced by swimming (i.e. it will no longer equal 1.5) The null hypothesis is that performance won’t be influenced by swimming. Now our hypotheses would look like this: H0: μdrug-μno_drug = 1.5 HA: μdrug-μno_drug 1.5 Note that conceptually H0 can still be thought of as ‘no difference’, in this case we are saying that the difference between the drug and no drug groups will not be different when the rats are swimming.
tobtained The tobtained score is still simply a standard score on the curve: i.e. the test statistic minus the mean of the curve divided by the standard deviation (standard error) of the curve.
Assumptions underlying this t test • Independence of scores (within and between groups) • Both populations normally distributed • The two populations have identical variances We will examine the assumption of identical variances in a latter lecture.
Effect Size Again the measures of effect size include: • Simply reporting the ‘raw’ effect size. • Reporting a standardized effect size. • Reporting the strength of association (which we will cover next semester).
‘Raw’ Effect Size This would be simply reporting the mean of the two groups and the difference between those means. In our experiment the mean number of wrong turns made by the ‘drug’ group was 7, the mean number for the ‘no drug’ group was 4, which is a difference of 3 between the two means.
Standardized Effect Size We will take a look at three standardized measures of effect size: • Cohen’s d • Hedges’s g • Glass’s Δ
Cohen’s d For the effect size in the population (exact, not estimated): Remember that an assumption underlying this t test is that both populations have the same variance (σY).
Cohen’s d For the effect size in the sample: If you examine the formula for Spooled you can see that it is simply the standard deviation of all the scores lumped into one group.
Hedges’s g Hedges’s g gives us an estimate of the effect size in the population form which we sampled. est. σpooled is a ‘pooled’ estimate of the standard deviation of Y, the formula combines the estimates of σY from the two groups, weighting each estimate based upon how many scores were in the group.
Glass’s Δ Glass’s delta is similar to Hedges’s g, but instead of using the scores from both groups to estimate the standard deviation of Y, delta just uses the data from the control group to estimate it.
Glass’s Δ In an experiment designed to test the effect of some treatment it is common to include a group that is handled exactly like the group that gets the treatment except without the treatment, this is called the ‘Control Group’ and the group that gets the treatment is called the ‘Treatment Group’. The reason the control group is named as it is will be covered in the lecture on confounding variables. In our example the rats given the drug constitute the ‘treatment group’ and those not given the drug are the ‘control group’.
Glass’s Δ Glass’s delta is used when there is reason to believe that the treatment applied to the treatment group might have affected not only the mean of the group but the variance of that group as well. If this is the case then the assumption of equal variances is not met (we will see how to analyze the data anyway later) and it makes no sense to use the variance of both groups to estimate the variance of Y, as they would actually be measuring two different variances, not one.
Useful Conversions ‘prop’ means ‘proportion’, so if 14 of the 20 scores were in group 1, then p1 would be 14/20 while p2 would be 6/20.