Testing coefficient of mediator, namely theta, in the outcome model. The outcome model is the following. outcome ~ intercept + G*gamma + mediator*theta + error
Generalized_Testing_coefficient_of_mediator(G,mediator,outcome,
covariates=NULL,outcome_type,
approxi=TRUE,verbose=FALSE)
n by p matrix (n rows and p columns). Each row is one individual; each column is one SNP.
a vector length of n. It is the mediator variable.
a vector length of n. It is the outcome variable.
n by r matrix (n rows and r columns). Each row is one individual; each column is one covariate.
Type of the outcome variable. "continuous" for a continuous outcome; "binary" for a binary outcome; "count" for a count outcome; "survival" for a survival outcome.
a boolean value. This is an indicator whether the approximation of computing derivatives is applied to save computing time. Default is TRUE.
a boolean value. If TRUE a lot of computing details is printed. Default is FALSE.
P value for testing the coefficient of mediator in the outcome model.
The point estimate of theta (coefficient of mediator) in the outcome model.