Description Usage Arguments Details Value References
Plots objects of class bsPDP
created by bootstrapping a predictive or causal model to show confidence bands for the average predicted partial dependence plot of a variable.
1 2 3 4 5 6 7 8 9 10 11 12 |
bsPDP |
(required) a list created by a
|
test |
is a logical indicating whether to plot the pdp for the test data instead of the train data (default is |
title |
is a string for the main title of the plot (the default is "Partial Dependence Plot"). |
xlim |
is a vector combination equal to the minimum and maximum values of the x-axis (the default is the minimum and maximum values of the x-variable). |
ylim |
is a vector combination equal to the minimum and maximum values of the y-axis (the default is the minimum of |
xtitle |
is a character string for the x-axis title (the default is the name of the x-variable) |
ytitle |
is a character string for the y-axis title (the default is "Predicted Outcome") |
iqr |
is a logical indicating whether to include lines at the IQR bounds of x (the default is |
hist |
is a logical indicating whether to include a histogram of x (the default is |
bsPDP
and plot.bsPDP
currently support the following methods:
lm
for linear models
glm
for generalized linear models
randomForest
for random forests
caret
for pramater tuning with machine-learning models (including tree ensembles and neural networks)
dbarts
and BayesTree
for Bayesian Additive Regression Trees (BART)
causaldrf
for inverse probability-of-treatment weights estimators iptw_est
and the Hirano-Imbens (2004) covariate balancing estimators hi_est
.
plot.bsPDP
returns a ggplot
that can bee manipulated according to ggplot
syntax.
Yakusheva, Olga; Bang, James T; Bobay, Kathleen; Hughes, Ronda G; Costa, Linda; and Weiss, Marianne (2021, Forthcoming). Health Services Research.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.