Description Usage Arguments Value Author(s) References Examples
This function performs hypothesis testing for the between-site variance of direct effect and that of indirect effect, besides providing the same output as given by the function msmediate().
1 | vartest.msmediate(data, y, treatment, mediator, X, site, npermute = 200)
|
data |
The data set for analysis. |
y |
The name of the outcome variable (string). |
treatment |
The name of the treatment variable (string). |
mediator |
The name of the mediator variable (string). |
X |
A vector of variable names (string) of pretreatment covariates, which will be included in the propensity score model. For now, the multilevel propensity score model only allows for one random intercept. |
site |
The variable name for the site ID (string). |
npermute |
The number of permutations for the permutation test. The default value is 200. It may take a long time, depending on the sample size and the length of X. |
A list contains the hypothesis testing results of the between-site variance of the causal effects, besides the same output as given by the function msmediate().
Xu Qin and Guanglei Hong
Qin, X., & Hong, G (2017). A weighting method for assessing between-site heterogeneity in causal mediation mechanism. Journal of Educational and Behavioral Statistics. Journal of Educational and Behavioral Statistics. Journal of Educational and Behavioral Statistics, 42(3), 308-340. doi: 10.3102/1076998617694879
1 2 3 4 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.