The function hte_plot
takes a model created by causal tree, as
well as the adjusted version, and
plots the distribution of the outcome variable in treated
and control groups in each leaf of the tree.
This visualization aims to show how the predicted
treatment effect changes with each split in the tree.
hte_plot(
model,
data,
treatment_indicator = NULL,
outcomevariable,
propensity_score,
plot.title = "Visualization of the Tree"
)
no return value
a tree model constructed by hte_causalTree, hte_matchinleaves,
or hte_ipw
.
a data frame containing the variables in the model.
a character representing the column name for the treatment variable in the causal setup.
a character representing the column name of the outcome variable.
a character representing the column name of the propensity score.
character representing the main title of the plot.