This adds a definition about how to display a moderators to the MCATE config. A moderator is any variable that you want to view information about CATEs with respect to.
add_moderator(hte_cfg, model_type, ..., .model_arguments = NULL)
HTE_cfg
object to update.
Character indicating the model type for these moderators.
Currently two model types are supported: "Stratified"
for discrete moderators
and "KernelSmooth"
for continuous ones.
The (unquoted) names of the moderator variables.
A named list from argument name to value to pass into the
constructor for the model. See Stratified_cfg
and KernelSmooth_cfg
for more details.
Updated HTE_cfg
object
library("dplyr")
basic_config() %>%
add_moderator("Stratified", x2, x3) %>%
add_moderator("KernelSmooth", x1, x4, x5) -> hte_cfg