Skip to contents

Produces a styled gt table of model coefficients. Supports linear, polynomial, logistic, ridge, lasso, and elastic net models.

Usage

tl_table_coefficients(model, lambda = "1se", digits = 4, ...)

Arguments

model

A tidylearn model object

lambda

For regularised models: "1se" (default) or "min"

digits

Number of decimal places (default: 4)

...

Additional arguments (currently unused)

Value

A gt table object.

Examples

# \donttest{
model <- tl_model(mtcars, mpg ~ wt + hp, method = "linear")
tl_table_coefficients(model)
Linear Model Coefficients
Term Estimate Std. Error t value p
(Intercept) 37.2273 1.5988 23.2847 2.57 × 10−20 *
wt −3.8778 0.6327 −6.1287 1.12 × 10−6 *
hp −0.0318 0.0090 −3.5187 1.45 × 10−3 *
tidylearn | linear (regression) | mpg ~ wt + hp | n = 32
# }