ComenzarEmpieza gratis

Using broom

Many programming tasks are easier if you keep all your data inside data frames. This is particularly true if you are a tidyverse fan, where dplyr and ggplot2 require you to use data frames. The broom package contains functions that decompose models into three data frames: one for the coefficient-level elements (the coefficients themselves, as well as p-values for each coefficient), the observation-level elements (like fitted values and residuals), and the model-level elements (mostly performance metrics).

The functions in broom are generic. That is, they work with many model types, not just linear regression model objects. They also work with logistic regression model objects (as you'll see in Chapter 4), and many other types of model.

mdl_price_vs_conv is available and broom is loaded.

Este ejercicio forma parte del curso

Introduction to Regression in R

Ver curso

Ejercicio interactivo práctico

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

# Get the coefficient-level elements of the model
___
Editar y ejecutar código