GenoScan.prelim: The preliminary data management for GenoScan

Description Usage Arguments Value Examples

Description

This function does the preliminary data management and fit the model under null hypothesis. The output will be used in the other GenoScan functions.

Usage

1
GenoScan.prelim(Y, X=NULL, id=NULL, out_type="C", B=5000)

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 phenotype with genotype. The default is NULL, where the matched phenotype and genotype matrices are assumed.

out_type

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

B

Number of resampling replicates. The default is 5000. A larger value leads to more accurate and stable p-value calculation, but requires more computing time.

Value

It returns a list used for function GenoScan.Region(), GenoScan.SingleWindow() and GenoScan.VCF.chr().

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
library(GenoScan)

# 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(GenoScan.example)
Y<-GenoScan.example$Y;X<-GenoScan.example$X;G<-GenoScan.example$G;Z<-GenoScan.example$Z

# Preliminary data management
result.prelim<-GenoScan.prelim(Y,X=X,out_type="C",B=5000)

GenoScan documentation built on May 2, 2019, 12:45 a.m.