3
\title{Score test for association in related people}
5
Score test for association between a trait and genetic polymorphism,
6
in samples of related individuals
9
mmscore(h2object,data,snpsubset,idsubset,strata,times=1,quiet=FALSE,bcast=10,clambda=TRUE,propPs=1.0)
12
\item{h2object}{An object returned by \code{\link{polygenic}} polygenic mixed model analysis
13
routine. The sub-objects used are measuredIDs, residualY, and InvSigma. One can supply
14
mmscore with a fake h2object, containing these list elements.
16
\item{data}{An object of \code{\link{gwaa.data-class}}.
17
ALWAYS PASS THE SAME OBJECT WHICH WAS USED FOR i\code{\link{polygenic}} ANALYSIS,
18
NO SUB-SETTING IN IDs (USE IDSUBSET ARGUMENT FOR SUB-SETTING)!!!}
19
\item{snpsubset}{Index, character or logical vector with subset of SNPs to run analysis on.
20
If missing, all SNPs from \code{data} are used for analysis.}
21
\item{idsubset}{Index, character or logical vector with subset of IDs to run analysis on.
22
If missing, all people from \code{data/cc} are used for analysis.}
23
\item{strata}{Stratification variable. If provieded, scores are computed within strata and
25
\item{times}{If more then one, the number of replicas to be used in derivation of
26
empirical genome-wide significance. NOTE: The structure of the data
27
is not exchangable, therefore do not use times > 1
28
unless you are really sure you understand what you are doing!
30
\item{quiet}{do not print warning messages}
31
\item{bcast}{If the argument times > 1, progress is reported once in bcast replicas}
32
\item{clambda}{If inflation facot Lambda is estimated as lower then one, this parameter
33
controls if the original P1df (clambda=TRUE) to be reported in Pc1df,
34
or the original 1df statistics is to be multiplied onto this "deflation"
35
factor (clambda=FALSE).
36
If a numeric value is provided, it is used as a correction factor.}
37
\item{propPs}{proportion of non-corrected P-values used to estimate the inflation factor Lambda,
38
passed directly to the \code{\link{estlambda}}}
41
Score test is performed using the formula
44
\frac{((G-E[G]) V^{-1} residualY)^2}{(G-E[G]) V^{-1} (G-E[G])}
47
where \eqn{G} is the vector of genotypes (coded 0, 1, 2) and \eqn{E[G]} is
48
a vector of (strata-specific) mean genotypic values; \eqn{V^{-1}} is the
49
InvSigma and \eqn{residualY} are residuals from the trait analysis
50
with \code{\link{polygenic}} procedure.
52
This test is similar to that implemented by Abecasis et al. (see reference).
55
Object of class \code{\link{scan.gwaa-class}}; only 1 d.f. test is
56
implemented currently.
59
Chen WM, Abecasis GR. Family-based association tests for genome-wide association
60
scans. Am J Hum Genet. 2007 Nov;81(5):913-26.
62
\author{Yurii Aulchenko}
65
\code{\link{grammar}},
66
\code{\link{qtscore}},
67
\code{\link{egscore}},
68
\code{\link{plot.scan.gwaa}},
69
\code{\link{scan.gwaa-class}}
72
# ge03d2 is rather bad data set to demonstrate grammar,
73
# because this is a population-based study
76
ge03d2.clean <- ge03d2.clean[1:450,]
77
gkin <- ibs(ge03d2.clean,w="freq")
78
h2ht <- polygenic(height ~ sex + age,kin=gkin,ge03d2.clean)
80
mm <- mmscore(h2ht,data=ge03d2.clean)
82
gr <- qtscore(h2ht$pgres,data=ge03d2.clean,clam=FALSE)
84
gc <- qtscore(height ~ sex + age,data=ge03d2.clean)
86
plot(mm,df="Pc1df",cex=0.5)
87
add.plot(gc,df="Pc1df",col="red")
88
add.plot(gr,df="Pc1df",col="lightgreen",cex=1.1)
89
# can see that mmscore and grammar are quite the same... in contrast to GC
91
\keyword{htest}% at least one, from doc/KEYWORDS