Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

pull_genoprobpos

Pull genotype probabilities for a particular position


Description

Pull out the genotype probabilities for a particular position (by name)

Usage

pull_genoprobpos(genoprobs, map = NULL, chr = NULL, pos = NULL, marker = NULL)

Arguments

genoprobs

Genotype probabilities as calculated by calc_genoprob().

map

A map object: a list (corresponding to chromosomes) of vectors of marker positions. Can also be a snpinfo object (data frame with columns chr and pos; marker names taken from column snp or if that doesn't exist from the row names)

chr

A chromosome ID

pos

A numeric position

marker

A single character string with the name of the position to pull out.

Details

Provide either a marker/pseudomarker name (with the argument marker) or all of map, chr, and pos.

Value

A matrix of genotype probabilities for the specified position.

See Also

Examples

iron <- read_cross2(system.file("extdata", "iron.zip", package="qtl2"))

gmap <- insert_pseudomarkers(iron$gmap, step=1)
pr <- calc_genoprob(iron, gmap, error_prob=0.002)

pmar <- find_marker(gmap, 8, 40)
pr_8_40 <- pull_genoprobpos(pr, pmar)

pr_8_40_alt <- pull_genoprobpos(pr, gmap, 8, 40)

qtl2

Quantitative Trait Locus Mapping in Experimental Crosses

v0.24
GPL-3
Authors
Karl W Broman [aut, cre] (<https://orcid.org/0000-0002-4914-6671>), R Core Team [ctb]
Initial release
2020-12-16

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.