ANOVA: Introduction Lecture Notes PDF
Document Details
Uploaded by Deleted User
Cardiff University
Richard Morey
Tags
Summary
These lecture notes provide an introduction to Analysis of Variance (ANOVA), focusing on one-way and two-by-two designs. The document includes examples, such as analyzing the effect of reward on math problem performance, and explains how to code for more groups. The lecture also reviews ANOVA assumptions and demonstrates different types of results visualizations, including boxplots, bar plots, dot plots, and a raincloud plot. Finally, it details factorial design examples and the concept of interactions, with practical illustrations and visual diagnostics.
Full Transcript
ANOVA: Introduction One-way and 2 by 2 designs Richard Morey PS2024 // Lecture 6 (Week 7) Regression vs ANOVA Same mathematical framework (GLM), but generally... Regression ANalysis Of VAriance (ANOVA) Observational data Continuous IVs...
ANOVA: Introduction One-way and 2 by 2 designs Richard Morey PS2024 // Lecture 6 (Week 7) Regression vs ANOVA Same mathematical framework (GLM), but generally... Regression ANalysis Of VAriance (ANOVA) Observational data Continuous IVs Experiments Focus on parameters Categorical IVs (usually "factors") Focus on factors 2 / 37 Categorical IVs Factors Non-factors Discrete levels/conditions Observed categorical manipulated variables, such as... experimentally, often randomly Gender Ethnicity Country of residence Generational cohort 3 / 37 One-way designs One-way designs have one factor, with more than two levels. Example Does reward for correct answers affect performance on math problems? DV: Score out of 100 points Factor 1: Reward (between-subjects) High reward (points are more money) Medium reward (points are money) Low reward (just points) 4 / 37 From two-group to one-way... Recall: Coding a regression for two groups Two groups needs one Three groups needs two variable. variables. Condition Var Var Var Condition High reward 1/2 1 2 Medium reward -1/2 High reward -1/2 1/2 Medium 1/2 1/2 reward Low reward 0 -1 5 / 37 One-way (three group) coding Coding a regression for three groups Variable 1 draws Three groups needs two distinction between variables. high, medium Variable 2 draws Var Var distinction between low, Condition 1 2 average of high and High reward -1/2 1/2 medium Medium 1/2 1/2 reward Low reward 0 -1 6 / 37 Coding for more groups K groups requires K − 1 variables "Degrees of freedom" Divides up the factor's SS into parts with distinct interpretations Many ways to do this! SPSS does it automatically Mostly beyond the scope of this module We begin by interpreting factors as a whole 7 / 37 Assumptions (review) In decreasing importance: Independence of observations Equality ("homogeneity") of variance of groups Normality of groups 8 / 37 Example Does reward for correct answers affect performance on math problems? DV: Score out of 100 points Factor 1: Reward (between-subjects) High reward (points are more money) Medium reward (points are money) Low reward (just points) 9 / 37 Results (boxplot) 10 / 37 Results (bar plot) 11 / 37 Results (dot plot) 12 / 37 Results (Raincloud plot) (see also "violin plots") 13 / 37 Descriptive statistics Std. Reward Mean N Condition Deviation Low 41.740 26.181 100 Medium 50.290 28.662 100 High 63.730 24.739 100 51.920 27.996 300 Total 14 / 37 Main ANOVA results Levene df1 df2 Sig. Statistic Based Performance on 1.448 2 297 0.237 Median Partial Sum of Mean Source df F Sig. Eta Squares Square squared Reward 24,576.540 2 12,288.270 17.398 0.000 0.105 Error 209,777.540 297 706.322 15 / 37 ANOVA table (important bits) Cell Interpretation How much variance does this factor F account for relative to the error? Is the F statistic bigger than we expect by Sig. chance? Eta squared Standardised effect size (discussed later) Mean squared Estimate of within-group ("error") variance error 16 / 37 "Follow-up" analyses Sometimes we want to know about differences among the groups. BUT: Danger of increased error through multiple tests! Solution Solution: Multiple comparison corrections 17 / 37 Tukey's "Honestly signiYcant difference" (HSD) How big would we expect the biggest difference to be, by chance? Depends on number of groups, MSE More groups → bigger "biggest" difference by chance HSD: Calculate all signiccant differences relative to the biggest difference we'd expect 18 / 37 Tukey "follow-up" analyses Multiple Comparisons Tukey HSD 95% Confidence Interval Mean (I) Reward (J) Reward Difference (I-J) Std. Error Sig. Lower Bound Upper Bound Low Medium −8.55 3.759 0.061 −17.40 0.30 Low High −21.99 3.759