Description Usage Arguments Value Examples
mte_at
evaluates marginal treatment effects at different
values of the latent resistance u
with a given X=x.
1 |
x |
Values of the pretreatment covariates at which \textup{MTE}(x, u) is evaluated. It should be a numeric vector whose length is one less than the number of columns of the design matrix X in the outcome model. Default is the sample means. |
u |
A numeric vector. Values of the latent resistance u at which \textup{MTE}(x, u) is evaluated. Note that the estimation involves extrapolation when the specified u values lie outside of the support of the propensity score. |
model |
A fitted MTE model returned by |
mte_at
returns a data frame.
u |
input values of |
x_comp |
the x-component of the estimated \textup{MTE}(x, u) |
u_comp |
the u-component of the estimated \textup{MTE}(x, u) |
value |
estimated values of \textup{MTE}(x, u) |
1 2 3 4 5 6 7 8 9 10 | mod <- mte(selection = d ~ x + z, outcome = y ~ x, data = toydata)
mte_vals <- mte_at(u = seq(0.05, 0.95, 0.1), model = mod)
if(require("ggplot2")){
ggplot(mte_vals, aes(x = u, y = value)) +
geom_line(size = 1) +
xlab("Latent Resistance U") +
ylab("Estimates of MTE at Mean Values of X") +
theme_minimal(base_size = 14)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.