View source: R/create_interactions.R
create_interactions | R Documentation |
Interactions as Violation Space Candidates
create_interactions(Z, X = NULL)
Z |
observations of the instrumental variable(s). Either a numeric vector of length n or a numeric matrix with dimension n by s. |
X |
observations of baseline covariate(s) for which interactions with the instrumental variable(s) should
be part of the violation space candidates. Either a numeric vector of length n
or a numeric matrix with dimension n by p or |
A list. The first element contains the observations of the
instrumental variable(s) Z
. The second element contains all interactions between
the instrumental variable(s) and the baseline covariate(s) X
.
Z <- matrix(rnorm(100 * 3), nrow = 100, ncol = 3)
X <- matrix(rnorm(100 * 3), nrow = 100, ncol = 3)
vio_space <- create_interactions(Z = Z, X = X)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.