Presentation is loading. Please wait.

Presentation is loading. Please wait.

Analysis of Covariance (ANCOVA)

Similar presentations


Presentation on theme: "Analysis of Covariance (ANCOVA)"— Presentation transcript:

1 Analysis of Covariance (ANCOVA)
Dr Dinesh Ramoo

2 Introduction It should, therefore, be no surprise that the regression equation for ANOVA can be extended to include one or more continuous variables that predict the outcome (or dependent variable). Continuous variables such as these, that are not part of the main experimental manipulation but have an influence on the dependent variable, are known as covariates and they can be included in an ANOVA analysis. When we measure covariates and include them in an analysis of variance we call it analysis of covariance (or ANCOVA for short).

3 Let’s think about things other than Viagra that might influence libido: well, the obvious one is the libido of the participant’s sexual partner (after all ‘it takes two to tango’!), but there are other things too such as other medication that suppresses libido (such as antidepressants or the contraceptive pill) and fatigue. If these variables (the covariates) are measured, then it is possible to control for the influence they have on the dependent variable by including them in the regression model. From what we know of hierarchical regression it should be clear that if we enter the covariate into the regression model first, and then enter the dummy variables representing the experimental manipulation, we can see what effect an independent variable has after the effect of the covariate.

4 As such, we partial out the effect of the covariate
As such, we partial out the effect of the covariate. There are two reasons for including covariates in ANOVA: To reduce within-group error variance: In the discussion of ANOVA and t-tests we got used to the idea that we assess the effect of an experiment by comparing the amount of variability in the data that the experiment can explain against the variability that it cannot explain. If we can explain some of this ‘unexplained’ variance (SSR) in terms of other variables (covariates), then we reduce the error variance, allowing us to more accurately assess the effect of the independent variable (SSM). Elimination of confounds: In any experiment, there may be unmeasured variables that confound the results (i.e. variables that vary systematically with the experimental manipulation). If any variables are known to influence the dependent variable being measured, then ANCOVA is ideally suited to remove the bias of these variables. Once a possible confounding variable has been identified, it can be measured and entered into the analysis as a covariate.

5 Assumptions and issues in ANCOVA
ANCOVA has the same assumptions as ANOVA except that there are two important additional considerations: (1) independence of the covariate and treatment effect, and (2) homogeneity of regression slopes.

6 Conducting ANCOVA on SPSS
Analyse  General Linear Models  Univariate Dependant Variable: Libido Fixed Factor(s): Dose Covariate(s): Partner_Libido Posthoc tests will be diabled

7 Conducting ANCOVA on SPSS
Contrasts  Contrast: Simple Reference category: First Click  Change Click  Continue

8 Click Options 

9 SPSS Output shows the results of Levene’s test and the ANOVA table when partner’s libido is included in the model as a covariate. Levene’s test is significant, indicating that the group variances are not equal (hence the assumption of homogeneity of variance has been violated). However, Levene’s test is not necessarily the best way to judge whether variances are unequal enough to cause problems. A good double-check is to look at the highest and lowest variances. For our three groups we have standard deviations of 1.79 (placebo), 1.46 (low dose) and 2.12 (high dose) – see Table If we square these values we get variances of 3.20 (placebo), 2.13 (low dose) and 4.49 (high dose). We then take the largest variance and divide it by the smallest: in this case 4.49/2.13=2.11. We can get the approximate critical value when comparing three variances and with 10 people per group (we have unequal groups, but this will do as an approximation). The critical value in this situation is approximately 5. Our observed value of 2.11 is less than this critical value of 5 so we probably don’t need to worry too much about the differences in variances.

10 The format of the ANOVA table is largely the same as without the covariate, except that there is an additional row of information about the covariate (Partner_Libido). Looking first at the significance values, it is clear that the covariate significantly predicts the dependent variable, because the significance value is less than .05. Therefore, the person’s libido is influenced by their partner’s libido. What’s more interesting is that when the effect of partner’s libido is removed, the effect of Viagra becomes significant (p is .027 which is less than .05). The amount of variation accounted for by the model (SSM) has increased to units (corrected model) of which Viagra accounts for units. Most important, the large amount of variation in libido that is accounted for by the covariate has meant that the unexplained variance (SSR) has been reduced to units. Notice that SST has not changed; all that has changed is how that total variation is explained.

11 SPSS Output shows the parameter estimates selected in the options dialog box. These estimates are calculated using a regression analysis with Dose split into two dummy coding variables. SPSS codes the two dummy variables such that the last category (the category coded with the highest value in the data editor – in this case the high-dose group) is the reference category. This reference category (labelled Dose=3 in the output) is coded with 0 for both dummy variables (see section for a reminder of how dummy coding works). Dose=2, therefore, represents the difference between the group coded as 2 (low dose) and the reference category (high dose), and dose=1 represents the difference between the group coded as 1 (placebo) and the reference category (high dose).

12 The b-values represent the differences between the means of these groups and so the significances of the t-tests tell us whether the group means differ significantly. The degrees of freedom for these t-tests can be calculated as in normal regression as N − p − 1 in which N is the total sample size (in this case 30) and p is the number of predictors (in this case 3, the two dummy variables and the covariate). For these data, df = 30 − 3 – 1 = 26. From these estimates we could conclude that the high-dose differs significantly from the placebo group (Dose=1 in the table) but not from the low-dose group (Dose=2 in the table).

13 The final thing to notice is the value of b for the covariate (0. 416)
The final thing to notice is the value of b for the covariate (0.416). This value tells us that, other things being equal, if a partner’s libido increases by one unit, then the person’s libido should increase by just under half a unit (although there is nothing to suggest a causal link between the two). The sign of this coefficient tells us the direction of the relationship between the covariate and the outcome. So, in this example, because the coefficient is positive it means that partner’s libido has a positive relationship with the participant’s libido: as one increases so does the other. A negative coefficient would mean the opposite: as one increases, the other decreases.

14 SPSS Output shows the result of the contrast analysis specified compares level 2 (low dose) against level 1 (placebo) as a first comparison, and level 3 (high dose) against level 1 (placebo) as a second comparison. These contrasts are consistent with what was specified: all groups are compared to the first group. The group differences are displayed: a difference value, standard error, significance value and 95% confidence interval. These results show that both the low-dose group (contrast 1, p = .045) and high-dose group (contrast 2, p = .010) had significantly different libidos than the placebo group. These results are consistent with the regression parameter estimates (in fact, note that contrast 2 is identical to the regression parameters for Dose=1 in the previous section).

15 These contrasts and parameter estimates tell us that there were group differences, but to interpret them we need to know the means. SPSS Output gives the adjusted values of the group means and it is these values that should be used for interpretation (this is the main reason for selecting the Display Means for option). The adjusted means (and our contrasts) show that levels of libido were significantly higher in the low and high-dose groups compared to the placebo group. The regression parameters also told us that the high- and low-dose groups did not significantly differ (p = .593). These conclusions can be verified with the post hoc tests specified in the options menu but normally you would do only contrasts or post hoc tests, not both.

16 SPSS Output shows the results of the Sidak-corrected post hoc comparisons that were requested as part of the options dialog box. The significant difference between the high-dose and placebo groups remains (p = .030), and the high-dose and low-dose groups do not significantly differ (p = .93). However, it is interesting that the significant difference between the low-dose and placebo groups shown by the regression parameters and contrasts is gone (p is only .13).

17 Reporting The covariate, partner’s libido, was significantly related to the participant’s libido, F(1, 26) = 4.96, p = .035, r = .40. There was also a significant effect of Viagra on levels of libido after controlling for the effect of partner’s libido, F(2, 26) = 4.14, p = .027, partial η2 = .24. Planned contrasts revealed that having a high dose of Viagra significantly increased libido compared to having a placebo, t(26) = −2.77, p = .01, r = .48, but not compared to having a low dose, t(26) = −0.54, p = .59, r = .11.

18 Questions?

19


Download ppt "Analysis of Covariance (ANCOVA)"

Similar presentations


Ads by Google