famSKAT {bigQF} | R Documentation |
Implicit matrix for family-based SKAT test
Description
Like link{SKAT.matrixfree}
but for the family-based test of Chen and colleagues
Usage
famSKAT(G, model,...)
## S3 method for class 'lmekin'
famSKAT(G, model, kinship, weights = function(maf) dbeta(maf, 1, 25),...)
## S3 method for class 'GENESIS.nullMixedModel'
famSKAT(G, model, threshold=1e-10, weights = function(maf) dbeta(maf, 1, 25),...)
## S3 method for class 'famSKAT_lmekin'
update(object,G,...)
## S3 method for class 'famSKAT_genesis'
update(object,G,...)
Arguments
G |
A 0/1/2 matrix whose columns are markers and whose rows are samples. Should be mostly zero. |
model |
Object representing a linear mixed model for covariate adjustment. Current methods are for class |
kinship |
The sparse kinship matrix: the |
threshold |
A threshold for setting elements of the phenotype precision matrix to exact zeros. |
weights |
A weight function used in SKAT: the default is the standard one. |
object |
An existing |
... |
for future expansion |
Value
An object of class c("famSKAT","matrixfree")
Note
The matrix and test statistic both differ by a factor of var(y)/2
from SKAT.matrixfree
when used with unrelated individuals (because the Chen et al reference differs from the original SKAT paper by the same factor)
References
Chen H, Meigs JM, Dupuis J (2013) Sequence Kernel Association Test for Quantitative Traits in Family Samples. Genet Epidemiol. 37(2): 196-204.
See Also
Examples
data(seqMetaExample)
m<-coxme::lmekin(y~sex+bmi+(1|id),data=pheno2,varlist=2*kins,
x=TRUE,y=TRUE,method="REML")
#first gene
g1snps<-c("1000001", "1000002", "1000003", "1000004", "1000005", "1000006",
"1000007", "1000008", "1000009", "1000010", "1000012", "1000013",
"1000014", "1000015")
Z2gene1<-Z2[,g1snps]
f<-famSKAT(Z2gene1, m, kins)
Q<-f$Q()
all.equal(Q, 56681.209)
## correct p is 0.742756401
pQF(Q,f,neig=4)
## gene10
g10snps<-as.character(1000017:1000036)
Z2gene10<-Z2[,g10snps]
f10<-update(f, Z2gene10)
Q10<-f10$Q()
all.equal(Q10,164656.19)
pQF(Q10,f10,neig=4)