Produces a styled gt table of model coefficients. Supports linear,
polynomial, logistic, ridge, lasso, and elastic net models. The numbers
come from tl_coefficients, which returns them as a tibble
if you would rather format them yourself.
Usage
tl_table_coefficients(
model,
lambda = "1se",
digits = 4,
conf_int = FALSE,
level = 0.95,
exponentiate = FALSE,
...
)Arguments
- model
A tidylearn model object
- lambda
For regularised models:
"1se"(default),"min", or a numeric penalty within the fitted path- digits
Number of decimal places (default: 4)
- conf_int
Whether to add a confidence interval (default:
FALSE). Not available for regularised models.- level
Confidence level for the interval (default: 0.95)
- exponentiate
Whether to report odds ratios rather than log odds (default:
FALSE). Classification models only.- ...
Additional arguments (currently unused)
Value
A gt table object.
See also
tl_coefficients for the underlying tibble.
Examples
# \donttest{
model <- tl_model(mtcars, mpg ~ wt + hp, method = "linear")
tl_table_coefficients(model)
Linear Model Coefficients
tidylearn | linear (regression) | mpg ~ wt + hp | n = 32
tl_table_coefficients(model, conf_int = TRUE)
Linear Model Coefficients
Wald 95% intervals
tidylearn | linear (regression) | mpg ~ wt + hp | n = 32
# }
