Diagnose Violations of Linear Regression Assumptions
Company: Snapchat
Role: Data Scientist
Category: Statistics & Math
Difficulty: medium
Interview Round: Technical Screen
State the assumptions needed to interpret ordinary least squares estimates and common inferential statistics. For each important assumption, explain how you would diagnose a possible violation and what you would change if the assumption does not hold.
### Constraints & Assumptions
- Distinguish assumptions needed for unbiased or consistent coefficient estimates from assumptions needed for conventional standard errors and exact small-sample tests.
- Do not treat a single diagnostic test as proof that an assumption is true.
- Include prediction concerns as well as coefficient interpretation.
### Clarifying Questions to Ask
- Is the goal causal interpretation, descriptive association, or out-of-sample prediction?
- Are observations cross-sectional, clustered, or ordered in time?
- Is the model intended to support confidence intervals and hypothesis tests?
- How large is the sample relative to the number of predictors?
```hint Organize by failure mode
Separate functional-form problems, dependence, unequal variance, collinearity, influential observations, and distributional assumptions.
```
### What a Strong Answer Covers
- Linearity in parameters and an adequate conditional-mean specification.
- Exogeneity and why residual plots cannot establish it.
- Independence or a correctly modeled dependence structure.
- Homoskedasticity, multicollinearity, influence, and residual normality in their proper roles.
- Diagnostics, remedies, and the limitations of each remedy.
### Follow-up Questions
- Which assumption is most important for a causal interpretation of one coefficient?
- When are heteroskedasticity-robust standard errors insufficient?
- How would your workflow change for a time series with autocorrelated errors?
Overview: Review linear regression assumptions by purpose, then connect each failure mode to diagnostics and remedies. Separate coefficient identification, standard-error validity, and predictive performance.
Read the full Snapchat Data Scientist interview experience this question came from