egscore(formula, data, snpsubset, idsubset, kinship.matrix, naxes = 3, strata, times = 1, quiet = FALSE, bcast = 10, clambda = TRUE, propPs = 1)
gwaa.data-class
data
are used for analysis.data/cc
are used for analysis.estlambda
scan.gwaa-class
hom
function (see example).The traits is first analysed using LM and with covariates as specified with formula and also with axes of variation as predictors. Corrected genotypes are defined as residuals from regression of genotypes onto axes (which are orthogonal). Correlaton between corrected genotypes and phenotype is computed, and test statistics is defined as square of this correlation times (N - K - 1), where N is number of genotyped subjects and K is the number of axes.
This test is defined only for 1 d.f.
qtscore
, mmscore
,
ibs
, scan.gwaa-class
require(GenABEL.data)
data(ge03d2c)
#egscore with stratification
gkin <- ibs(ge03d2c[,autosomal(ge03d2c)],w="freq")
#replace the diagonal with right elements
diag(gkin) <- hom(ge03d2c[,autosomal(ge03d2c)])$Var
a <- egscore(dm2~sex+age,data=ge03d2c,kin=gkin)
plot(a,df="Pc1df")
Run the code above in your browser using DataLab