glm_indirect_jointest: Function to test indirect effects of exposure and potential...

Description Usage Arguments Details Value Author(s) References

View source: R/glm_indirect_jointest.R

Description

The effect of exposure on the potential mediator is tested by linear regression model. And the joint effect of the exposure and mediator on the outcome is tested by logistic regression model.

Usage

1

Arguments

data

The tested data matrix with dimension of n by 3. The rows represent n subjects. The column 1, 2, 3 represent the data for the exposure variable, outome variable, and potential mediator, respectively.

Details

See https://stat.ethz.ch/R-manual/R-devel/library/stats/html/lm.html
https://stat.ethz.ch/R-manual/R-devel/library/stats/html/glm.html

Value

pvalue

A vector consisting of p-values of the two tests.

Author(s)

Original lm: R Core Team and contributors worldwide
Original glm: R Core Team and contributors worldwide

References

Original lm: Chambers, J. M. (1992) Linear models. Chapter 4 of Statistical Models in S eds J. M. Chambers and T. J. Hastie, Wadsworth & Brooks/Cole.
Wilkinson, G. N. and Rogers, C. E. (1973). Symbolic descriptions of factorial models for analysis of variance. Applied Statistics, 22, 392–399. doi: 10.2307/2346786.

Original glm: Dobson, A. J. (1990) An Introduction to Generalized Linear Models. London: Chapman and Hall.
Hastie, T. J. and Pregibon, D. (1992) Generalized linear models. Chapter 6 of Statistical Models in S eds J. M. Chambers and T. J. Hastie, Wadsworth & Brooks/Cole.
McCullagh P. and Nelder, J. A. (1989) Generalized Linear Models. London: Chapman and Hall.
Venables, W. N. and Ripley, B. D. (2002) Modern Applied Statistics with S. New York: Springer.


Jiasong-Duan/EMscreening documentation built on June 10, 2021, 11:13 a.m.