Description Usage Arguments Value See Also
Gaussian Process Regression for Regression Discontinuity
1 2 3 4 5 6 7 8 9 |
x |
A numeric vector giving the observations of the explanatory variable |
y |
A numeric vector giving the observations of the outcome |
cutoff |
A numeric vector of length one giving the discontinutiy cutoff; the default is 0. |
estimator |
A character vector of length one giving the estimation strategy; should be one of "global" (one unknown function for all observations, with dummy variable added to indicate treatment) or "piecewise" (different unknown functions for observations to the left of the cutoff and to the right). The default is "piecewise". |
hypers |
A list giving the hyperparameters of the model. If
|
ci_width |
A numeric vector of length one between 0 and 1 giving the width of the confidence interval for the treatment effect. |
A list of length five with class gprd
and elements
The treatment effect estimate
A named numeric ector of length two giving the requested confidence interval (the names are the confidence interval quantiles)
A numeric vector of length one giving the cutoff
A character vector of length one giving the estimation strategy
A list where each element is an object of class gpr
with information on the posterior over the relevant
function; if estimator = "global"
, the list will be
of length one, giving the posterior over the global mapping
from x
to y
, while if
estimator = "piecewise"
, the list will be of length two
with elements f_l
(giving the posterior over the
function to the left of the cutoff) and f_r
(giving
the posterior over the function to the right of the cutoff)
An object of class gpr
is a list of length eight with the following
elements:
The mean of the predictive distribution at test
cases test_input
; in this case, the cutoff
The variance of the predictive distribution at test
cases test_input
; in this case, the cutoff
The mean of the posterior of the linear mean coefficients
The input variable obervations for training cases
The outcome observations for training cases
The input variable observations predictions were provided for
The covariance function evaluated for the training inputs, with observation noise added
The inverse of prior_covariance
;
having this available is useful for generating
other predictions
The hyperparameters used for the GP regression,
provided in a list of length five:
beta_prior_cov
, giving the
beta prior covariance;
beta_prior_mean
, giving the beta prior
mean;
sigma_f
, giving the scale factor for the
GP prior;
ell
, giving the length scale for the GP
prior;
and sigma_y
, giving the outcome observation
noise (the likelihood hyper).
plot.gprd
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.