| synth_spec_model_api | R Documentation |
synth_spec objectAdd, update, or remove custom models from a synth_spec object
add_custom_models(synth_spec, ...)
update_custom_models(synth_spec, ...)
remove_custom_models(synth_spec)
synth_spec |
A |
... |
Optional named lists with two elements, |
A new synth_spec object.
A new synth_spec object with added custom models.
A new synth_spec object with updated custom models.
A new synth_spec object with removed custom models.
synth_spec <- synth_spec()
dt_reg_mod <- parsnip::decision_tree() |>
parsnip::set_engine("rpart") |>
parsnip::set_mode("regression")
add_custom_models(
synth_spec = synth_spec,
list("vars" = c("a", "b", "c"), "model" = dt_reg_mod)
)
synth_spec <- synth_spec()
dt_reg_mod <- parsnip::decision_tree() |>
parsnip::set_engine("rpart") |>
parsnip::set_mode("regression")
update_custom_models(
synth_spec = synth_spec,
list("vars" = c("a", "b", "c"), "model" = dt_reg_mod)
)
synth_spec <- synth_spec()
dt_reg_mod <- parsnip::decision_tree() |>
parsnip::set_engine("rpart") |>
parsnip::set_mode("regression")
synth_spec <- update_custom_models(
synth_spec = synth_spec,
list("vars" = c("a", "b", "c"), "model" = dt_reg_mod)
)
remove_custom_models(synth_spec = synth_spec)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.