ComenzarEmpieza gratis

Evaluating and comparing imputations

When you build up an imputation model, it's a good idea to compare it to another method. In this lesson, we are going to compare the previously imputed dataset created using impute_lm() to the mean imputed dataset. Both of these datasets are included in this exercise as ocean_imp_lm_wind and ocean_imp_mean respectively.

Este ejercicio forma parte del curso

Dealing With Missing Data in R

Ver curso

Instrucciones del ejercicio

  • Bind the models together using bind_rows(), placing the ocean_imp_mean model into mean, and ocean_imp_lm_wind into lm_wind.
  • Look at the values of air_temp and humidity as a scatter plot, placing air_temp_c on the x-axis, humidity on the y-axis, color by any missings, and faceting by imputation model used (imp_model).

Ejercicio interactivo práctico

Prueba este ejercicio y completa el código de muestra.

# Bind the models together 
bound_models <- bind_rows(mean = ___,
                          lm_wind = ___,
                          .id = "imp_model")

# Inspect the values of air_temp and humidity as a scatter plot
ggplot(___, 
       aes(x = ___, 
           y = ___, 
           color = any_missing)) +
  geom_point() + 
  facet_wrap(~___)
Editar y ejecutar código