Learn R Programming

sommer (version 1.1)

score.calc: Score calculation for markers

Description

This function is a wrapper from the rrBLUP package to be used when a mixed model including markers to perform GWAS is specified and once the variance components have been estimated the fixed effects are obtained as B= (X'V-X)-X'V-y and the score calculation is obtained with the F statistic as F = Beta^2 / Var(Beta) where Var(Beta) = SSe/(n-p) * [XH-X']-, and quantile value for the beta distribution is calculated as q = (n-p) / (n-p + 1 * F) which once obtained, the -log10 for such value is the score value.

Usage

score.calc(M, y, ZO, Hinv, min.MAF, X2, P3D=TRUE, method="AI", 
           iters=50, R=NULL, REML=TRUE, draw=TRUE)

Arguments

M
marker matrix
y
response variable
ZO
incidence matrix of random effects
Hinv
inverse of the phenotypic variance matrix
min.MAF
minimum minor allele frequency
X2
incidence matrix X as full rank from eigen decomposition
P3D
When P3D=TRUE, variance components are estimated by REML only once, without any markers in the model. When P3D=FALSE, variance components are estimated by REML for each marker separately. The default is the first case.
method
this refers to the method or algorithm to be used for estimating variance components. The package currently is supported by 3 algorithms; "EMMA" efficient mixed model association (Kang et al. 2008), "AI" average information (Gilmour et al. 1995; Lee et al
iters
a scalar value indicating how many iterations have to be performed if the EM algorithm is selected. There is no rule of tumb for the number of iterations. The default value is 50 iterations or EM steps, but could take less or much longer than that.
R
a matrix for variance-covariance structures for the residuals, i.e. for longitudinal data. if not passed is assumed an identity matrix.
REML
a TRUE/FALSE value indicating if restricted maximum likelihood should be used instead of ML. The default is TRUE.
draw
a TRUE/FALSE value indicating if a plot of updated values for the variance components and the likelihood should be drawn or not. The dafault is TRUE.

Value

  • [object Object]

Examples

Run this code
# it works internally in the \code{\link{mixed.solver}} function

Run the code above in your browser using DataLab