1/17
Looks like no tags are added yet.
What is ANCOVA?
A GLM with both categorical and numeric predictors
ANCOVA is a GLM with both categorical and numeric predictors. The numeric covariate explains extra variance and can reduce error variance.
What is a covariate?
A variable not part of the main manipulation that may influence the DV
A covariate isn't the manipulated variable, but it may influence the DV, such as mother's weight when predicting infant weight from smoking status.
What are the two main reasons for adding covariates?
Reduce error variance, and adjust for confounds (if the covariate is independent of the manipulation)
Covariates (1) reduce within-group error variance, improving the test of the IV, and (2) adjust for confounds, though this only works if the covariate is independent of the experimental effect.
In dummy (treatment contrast) coding, what do the intercept and slope represent?
Intercept = reference level mean; slope = difference between that level and the reference
Dummy coding sets one level as the reference (0) and compares others to it (1). The intercept is the reference mean and each slope is a difference from it.
How many dummy variables does a factor with 3 levels produce?
2
A variable with k levels gets k − 1 contrasts: here 2 for none/low/high.
Which level does R use as the reference by default, and how can you change it?
The lowest alphabetically ordered level (change it with fct_relevel())
R picks the alphabetically first level as the reference. Use fct_relevel() to put the factor levels in the order you want.
In lm(Birthweight ~ smoker), the intercept is 7.74 and smokeryes is −0.83. What do they mean?
Intercept = 7.74 (non-smokers' mean); slope = −0.83 (smokers minus non-smokers)
With smoker = yes as the dummy, the intercept is the non-smoker mean (7.74) and smokeryes (−0.83) is the difference (smokers' mean 6.91).
Why centre a numeric covariate such as mother's weight?
It makes the intercept refer to the average value of the covariate rather than 0
Centring subtracts the variable's mean so the intercept is the expected DV for someone at the average covariate value instead of at 0, which is often meaningless.
In lm(Birthweight ~ smoker + mppwt_c), what does the intercept (7.74) represent?
Expected baby weight for non-smoking mothers of average weight
Non-smoker is the reference and mother's weight is centred, so the intercept is the expected baby weight for non-smokers of average weight.
In the ANCOVA model, what does the smokeryes coefficient (−0.83) show?
The unique effect of smoking after adjusting for mother's weight
Each variable is adjusted for all the others. 'smokeryes' is the unique effect of smoking after adjusting for mother's weight (and vice versa).
What does the model without an interaction assume?
That mother's weight has the same association with baby weight for smokers and non-smokers (parallel lines)
The additive (no interaction) model fits parallel lines with a common mother-weight slope. An interaction term lets the slope differ between smokers and non-smokers.
In the Week 4 data, what happened when the smoker × mother's weight interaction was added?
It's not significant and adjusted R² fell, so it adds nothing
The interaction (p = .717) was not significant and adjusted R² fell from 0.22 to 0.20, so the interaction doesn't help the model.
How do you interpret anova(model1, model2) for nested models?
Look for a significant p and smaller RSS; if not significant, prefer the simpler model
anova(m1, m2) compares nested models. A significant p favours the more complex model, and a smaller RSS means better fit. A non-significant result means the simpler model is preferred.
In anova(m3, m4), p = .7166. What is the conclusion?
The models don't differ (p = .72), so the simpler model without the interaction is preferred
The slides' output was F = 0.1337, p = .7166, RSS 53.818 vs 53.629, so the simple model without the interaction is preferred.
What does "linear" mean in the general linear model (Poldrack, ch. 14)?
That the model is linear in its parameters (not necessarily a straight line)
Linear means linear in the parameters: predictors are just multiplied by parameters. Curved fits are possible. Binary outcomes use generalised linear models.
What is regression to the mean, and what protects against being fooled by it?
Extreme scores tend to move toward the mean on retest; use a randomised control group
Galton found that children of extreme parents fall closer to the mean. In experiments, people selected for extreme scores will move toward the mean on retest by chance, so you need a randomised untreated control group.
How is the regression slope related to the correlation r?
β = r × (sy / sx)
β̂x = r × (sy / sx). When x and y have equal SDs (e.g. z-scores), the slope equals the correlation.
What is overfitting, and how does cross-validation help?
It fits the noise in the original data, so fit on that data is inflated; cross-validation gives a more honest estimate
Overfitting: a model with many parameters fits the noise in the original data (32 parameters for 48 children), so it predicts new data far worse. Cross-validation, which fits the model repeatedly leaving out held-out subsets, gives a more honest estimate (R² 0.60 vs 0.95 original and 0.34 new).