Session Ready
Exercise

Glance at the fit of your models

In this exercise you will use glance() to calculate how well the linear models fit the data for each country.

Instructions
100 XP
  • Append a column (fit) containing the fit statistics for each model to the gap_models dataframe and save it as model_perf_nested.
  • Simplify this dataframe using unnest() to extract these fit statistics of each model and save it as model_perf.
  • Finally, use head() to take a peek at model_perf.