Soc 3306 a ANOVA and Regression Models OneWay

  • Slides: 8
Download presentation
Soc 3306 a: ANOVA and Regression Models

Soc 3306 a: ANOVA and Regression Models

One-Way ANOVA (Figure 1) Used when model has a quantitative response variable (DV) and

One-Way ANOVA (Figure 1) Used when model has a quantitative response variable (DV) and a categorical explanatory variable (IV) n Actually special type of multiple regression. n Need a post hoc test for more information (to tell you which groups different) n Most common are the Tukey b test (displays group means) or the Bonferroni or the Tukey multiple comparison methods (confidence intervals) n

Regression with Dummy Variable (Figure 2) Can get same result with regression model if

Regression with Dummy Variable (Figure 2) Can get same result with regression model if create a dummy variable n But M. R. provides more information n Advantage is that regression calculates slopes to use for prediction as well as standardized coefficients, plots, etc. n With binary categorical variable can create dummy coded 1 and 0 n But if categorical variable has 2+ categories, need to create K-1 dummies n

Creating Dummy Variables for Race (1 White, 2 Black, 3 Other) Use Recode into

Creating Dummy Variables for Race (1 White, 2 Black, 3 Other) Use Recode into Different Variable n Code Dummy 1 as White = 1, Else = 0 n Code Dummy 2 as Black = 1, Else = 0 n Don’t need a dummy variable for last group n Dummy Coding: Race Dummy 1 Dummy 2 White 1 0 Black 0 1 Other 0 0 n

Interpretation of Dummy Variable n E(Y) = a + b 1(Dummy 1) + b

Interpretation of Dummy Variable n E(Y) = a + b 1(Dummy 1) + b 2(Dummy 2) n For White: Dummy 1 = 1, Dummy 2 = 0 For Black: Dummy 1 = 0, Dummy 2 = 1 For Other: Dummy 1 = 0, Dummy 2 = 0 n n (Agresti and Finlay (the optional reading) gives a good explanation of this in Ch. 12 Table 12. 5)

Regression Using 2 Dummies (Race and Sex) Figure 3 n Dummysex coded Male=1 and

Regression Using 2 Dummies (Race and Sex) Figure 3 n Dummysex coded Male=1 and Female=0 n E(Y) = a + b 1(Dummy 1) + b 2(Dummy 2)+ b 3(Dummysex) n White Male: Dummy 1 = 1, Dummy 2 = 0, Dummysex = 1 Black Male: Dummy 1 = 0, Dummy 2 = 1, Dummysex = 1 Other Male: Dummy 1 = 0, Dummy 2 = 0, Dummysex = 1 White Female: Dummy 1 = 1, Dummy 2 = 0, Dummysex = 0 Black Female: Dummy 1 = 0, Dummy 2 = 1, Dummysex = 0 Other Female: Dummy 1 = 0, Dummy 2 = 0, Dummysex = 0 n n n

Two Way ANOVA Figure 4 Two way ANOVA, using GLM, handles 2 or more

Two Way ANOVA Figure 4 Two way ANOVA, using GLM, handles 2 or more categorical predictors at the same time n Recoding as dummies not needed n Compares means of response variable (DV) for all combinations of 2+ categorical IV’s n Can test main effects as well as interaction effects simultaneously n

Univariate GLM compared to Multiple Linear Regression Figure 5 n n n GLM can

Univariate GLM compared to Multiple Linear Regression Figure 5 n n n GLM can be used for linear regression using both categorical and quantitative predictors. Categorical IV’s entered as fixed factors and quantitative IV’s are entered as covariates GLM ¨ Dummy coding not needed ¨ Interactions between categorical IV’s handled easily ¨ Need to ask for parameter estimates n Linear regression ¨ Gives parameter estimates and standardized coefficients (i. e. to estimate causal models using path analysis)