FST.prelim {FSTpackage}R Documentation

The preliminary data management for FST (functional score tests)

Description

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

Usage

FST.prelim(Y, X=NULL, id=NULL, out_type="C")

Arguments

Y

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

X

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

id

The subject id. This is used to match the genotype matrix. The default is NULL, where the a matched phenotype and genotype matrix is assumed.

out_type

Type of outcome variable. Can be either "C" for continuous or "D" for dichotomous. The default is "C".

Value

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

Examples

library(FSTpackage)

# Load data example
# Y: outcomes, n by 1 matrix where n is the total number of observations
# X: covariates, n by d matrix
# G: genotype matrix, n by p matrix where n is the total number of subjects
# Z: functional annotation matrix, p by q matrix

data(FST.example)
Y<-FST.example$Y;X<-FST.example$X;G<-FST.example$G

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


[Package FSTpackage version 0.1 Index]