GA.prelim: The preliminary data management for GA (tests for genetic...

Description Usage Arguments Value Examples

View source: R/GA.R

Description

Before testing a specific region using a generalized score type test, this function does the preliminary data management, such as fitting the model under the null hypothesis.

Usage

1
GA.prelim(Y,time,X=NULL,corstr="exchangeable")

Arguments

Y

The outcome variable, an n*1 matrix where n is the total number of observations

time

An n*2 matrix describing how the observations are measured. The first column is the subject id. The second column is the measured exam (1,2,3,etc.).

X

An n*p covariates matrix where p is the total number of covariates.

corstr

The working correlation as specified in 'geeglm'. The following are permitted: "independence", "exchangeable", "ar1".

Value

It returns a list used for function GA.test().

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
library(LGEWIS)

# Load data example
# Y: outcomes, n by 1 matrix where n is the total number of observations
# X: covariates, n by p matrix
# time: describe longitudinal structure, n by 2 matrix
# G: genotype matrix, m by q matrix where m is the total number of subjects

data(LGEWIS.example)
Y<-LGEWIS.example$Y
X<-LGEWIS.example$X
time<-LGEWIS.example$time
G<-LGEWIS.example$G

# Preliminary data management
result.prelim<-GA.prelim(Y,time,X=X)

LGEWIS documentation built on May 2, 2019, 3:48 p.m.

Related to GA.prelim in LGEWIS...