predict.rd {rddapp} | R Documentation |
Predict the Regression Discontinuity
Description
predict.rd
makes predictions of means and standard deviations of RDs at different cutoffs.
Usage
## S3 method for class 'rd'
predict(object, gran = 50, ...)
Arguments
object |
An |
gran |
A non-negative integer specifying the granularity of the data points (i.e. the desired number of predicted points). The default is 50. |
... |
Additional arguments passed to |
Examples
set.seed(12345)
x <- runif(1000, -1, 1)
cov <- rnorm(1000)
y <- 3 + 2 * x + 3 * cov + 10 * (x >= 0) + rnorm(1000)
tr <- as.integer(x >= 0)
rd <- rd_est(y ~ x + tr | cov, cutpoint = 0, t.design = "geq")
predict(rd)
[Package rddapp version 1.3.2 Index]