Week 7

Assessing Model Fit
Published

May 13, 2024

Modified

May 16, 2024

Resources

Lesson Topic Slides Annotated Slides Recording
12 Assessing Model Fit
13 Numerical Problems

pdf on github

On the Horizon

Class Exit Tickets

Monday (5/13)

Quiz starts on Wednesday (5/15)

Announcements

Monday 5/13

  • I will review our interaction notes from last time
  • Quiz 2 opens on Wednesday at 2pm!!
    • Will cover Lessons 5-9!!
    • Mostly on Lessons 5-8, with one question about concepts covered in Lesson 9 (like types of missing data…)
      • Think about how we fit logistic regression and GLMs
      • Think about link functions!
      • Think about our tests (Wald, Score, LRT)
      • Think about the different transformations between Y, probability, and logit!
      • Think about what our predictions mean
      • Think about interpretations within logistic regression.
  • Lab 2
    • I noticed that a lot of you did not comment on the trends from the bivariate analysis
      • This is why I didn’t have us use ggpairs() last quarter. It’s too easy to just blow past this.
      • Getting to know your data and the trends you see in the sample is incredibly important!!
      • The best way to identify issues with your model is to have a good understanding of your data and their trends
    • Many people noticed small cell counts for income levels
      • We will address this issues in lecture this week!
    • Unless you are removing food insecurity from any hardship or multiple hardships, do NOT use these variables!

Muddiest Points

1. How do we determine the number of covariate patterns in R?

Theoretically, all you need to do is count the number of groups in each categorical covariates. To find the total number of covariate patterns, you multiple those numbers by each other.

In R, we can take a dataframe with only the predictors in your model. You can use the distinct() function to create unique rows. The number of rows outputted will be the number of covariate patterns.