stud_err: Studentized error variable

Description Usage Arguments Value Examples

View source: R/quantile.R

Description

Calculates the studentized error term given weights, residuals, and conditional variance matrix.

Usage

1
stud_err(w.1, w.0, resid.1, resid.0, omega.1, omega.0, T.grad)

Arguments

w.1

A n_1 by k dimensional matrix of weight values corresponding to treated observations

w.0

A n_0 by k dimensional matrix of weight values corresponding to control observations

resid.1

A n_1 by k dimensional matrix of residuals corresponding to treated observations

resid.0

A n_0 by k dimensional matrix of residuals corresponding to control observations

omega.1

A n_1 by k by k array of conditional variance corresponding to treated observations

omega.0

A n_0 by k by k array of conditional variance corresponding to control observations

T.grad

A k dimensional gradient vector of T_t f

Value

A studentized scalar estimation error term

Examples

1
2
3
4
5
6
7
stud_err(rep(1/50, 50), rep(1/50, 50), stats::rnorm(50),
stats::rnorm(50), rep(1, 50), rep(1, 50), 1)
w.1 <- w.0 <- matrix(rep(1/50, 100), ncol = 2)
resid.1 <- resid.0 <- matrix(stats::rnorm(100), ncol = 2)
omega.1 <- omega.0 <- array(rep(c(1,0,0,1), each = 50), dim = c(50, 2, 2))
T.grad <- c(1, 1)
stud_err(w.1, w.0, resid.1, resid.0, omega.1, omega.0, T.grad)

koohyun-kwon/HTEBand documentation built on Dec. 21, 2021, 7:42 a.m.