d <- subset(
get_it_dunn_run,
race == "5k" & date == "2018-05-12" &
!is.na(age) & state %in% c("MN", "WI")
)
head(d)
m <- lm(run_time_minutes ~ sex + age + state, d)
summary(m)
plot(m$fitted, m$residuals)
boxplot(m$residuals ~ d$sex)
plot(m$residuals ~ d$age)
hist(m$residuals)
Run the code above in your browser using DataLab