CLAN {GenericML} | R Documentation |
Performs CLAN
Description
Performs Classification Analysis (CLAN) on all variables in a design matrix.
Usage
CLAN(
Z_CLAN,
membership,
equal_variances = FALSE,
diff = setup_diff(),
significance_level = 0.05
)
Arguments
Z_CLAN |
A numeric matrix holding variables on which classification analysis (CLAN) shall be performed. CLAN will be performed on each column of the matrix. |
membership |
A logical matrix that indicates the group membership of each observation in |
equal_variances |
If |
diff |
Specifies the generic targets of CLAN. Must be an object of class |
significance_level |
Significance level. Default is 0.05. |
Value
An object of the class "CLAN"
, consisting of the following components:
generic_targets
A list of result matrices for each variable in
Z_CLAN
. Each matrix contains inferential results on the CLAN generic targets.coefficients
A matrix of point estimates of each CLAN generic target parameter.
References
Chernozhukov V., Demirer M., Duflo E., Fernández-Val I. (2020). “Generic Machine Learning Inference on Heterogenous Treatment Effects in Randomized Experiments.” arXiv preprint arXiv:1712.04802. URL: https://arxiv.org/abs/1712.04802.
See Also
quantile_group()
,
setup_diff()
Examples
## generate data
set.seed(1)
n <- 150 # number of observations
p <- 5 # number of covariates
Z_CLAN <- matrix(runif(n*p), n, p) # design matrix to perform CLAN on
membership <- quantile_group(rnorm(n)) # group membership
## perform CLAN
CLAN(Z_CLAN, membership)