fitqtlShape: fitqtlShape

Description Usage Arguments Details Value Author(s) Examples

View source: R/qtleffect_shape.R

Description

Estimates qtl effect

Usage

1
2
fitqtlShape(cross, pheno.col, qtl, covar = NULL, formula, method = "hk",
  forceXcovar = FALSE, pca = NULL)

Arguments

cross

A cross object containing genotypes and some phenotypes

pheno.col

A numerical vector with column indicies in cross$pheno of the phenotypes to map or a vector containing their names.

qtl

An

covar

An optional data.frame of covariates

formula

A formula ccc

method

Indicates whether to use multiple imputation or Haley-Knott regression. Only 'hk' is tested so far.

forceXcovar

Not use so far. Keep it default.

pca

An optional prcomp object from prcomp function use to get PC scores or just the corresponding eigenvector matrix. Use to return the effect in their original coordinates (PCscores back to tgCoords)

Details

Function takes a cross object

Value

Function returns qtl effects

Author(s)

Nicolas Navarro

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
data(fake.bc)
fake.bc <- update.cross(fake.bc, phen2keep=colnames(fake.bc$pheno))
fake.bc <- calc.genoprob(fake.bc)
qtl <- makeqtl(fake.bc, chr = c(1, 8, 13), pos=c(26, 56, 28), what="prob")
eff <- fitqtlShape(fake.bc, pheno.col=grep('pheno',colnames(fake.bc$pheno)), qtl)
# Using PC scores
pca <- prcomp(fake.bc$pheno[,c('pheno1','pheno2')])
PCs <- data.frame(Id=1:nrow(pca$x), pca$x)
fake.bc <- update(fake.bc, new.pheno=PCs)
eff <- fitqtlShape(fake.bc, pheno.col=grep("PC",colnames(fake.bc$pheno)), qtl, pca=pca)

nnavarro/shapeQTL documentation built on April 30, 2021, 12:10 p.m.