Learn R Programming

rMVP (version 0.99.14.1)

MVP.EMMA.Vg.Ve: Estimate variance components using EMMA

Description

Build date: August 30, 2016 Last update: January 27, 2017

Usage

MVP.EMMA.Vg.Ve(y, X, K, ngrids = 100, llim = -10, ulim = 10,
  esp = 1e-10)

Arguments

y

phenotype, n * 2

X

covariate matrix, the first column is 1s

K

Kinship matrix

ngrids

parameters for estimating vg and ve

llim

parameters for estimating vg and ve

ulim

parameters for estimating vg and ve

esp

parameters for estimating vg and ve

Value

Output: REML - maximum log likelihood Output: delta - exp(root) Output: ve - residual variance Output: vg - genetic variance

Examples

Run this code
# NOT RUN {
phePath <- system.file("extdata", "07_other", "mvp.phe", package = "rMVP")
phenotype <- read.table(phePath, header=TRUE)
print(dim(phenotype))
genoPath <- system.file("extdata", "06_mvp-impute", "mvp.imp.geno.desc", package = "rMVP")
genotype <- attach.big.matrix(genoPath)
print(dim(genotype))
K <- MVP.K.VanRaden(genotype)
vc <- MVP.EMMA.Vg.Ve(y=phenotype[,2], X=matrix(1, nrow(phenotype)), K=K)
print(vc)
# }

Run the code above in your browser using DataLab