| y_model | R Documentation |
Specify a working model for a study variable y
y_model(formula, engine = c("glm", "tree", "forest", "boost"), family = NULL)
formula |
full formula, e.g. income ~ sex + age_g. |
engine |
"glm", "tree" (rpart), "forest" (ranger) or "boost" (xgboost). The flexible learners run with fixed default settings (hyperparameters are not currently exposed): "tree"/"forest" use the 'rpart'/'ranger' defaults, and "boost" uses xgboost with nrounds = 150, max_depth = 4 and eta = 0.1. |
family |
for engine = "glm": "gaussian", "binomial" or "poisson". For tree/forest, regression vs classification is inferred from y. |
a model specification list.
y_model(income ~ age + sex, engine = "glm")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.