callGtFromAd: call genotype from AD

Description Usage Arguments Value Author(s) Examples

View source: R/callGtFromAd.R

Description

call genotype from AD

Usage

1
2
callGtFromAd(x, min.depth = 10, max.depth = 200, low = 0.2,
  high = 0.8)

Arguments

x

AD matrix

min.depth

minimum depth to infer the genotype, if depth lower than it, it will be conside as NA

max.depth

maximum depth to infer the genotype, if depth larger than it, it will be conside as NA

low

threshold to infer one parent, encoded as 0

high

threshold to infer another parent, encoded as 2

Value

matrix contains. The allele depth will convet to genotype

Author(s)

Zhougeng Xu

Examples

1
2
3
4
AD <- matrix(data = c("30,1","1,30","0,0","15,15"), nrow = 2)
row.names(AD) <- c("chr1_1","chr1_100")
colnames(AD) <- c("A","B")
geno <- callGtFromAd(AD)

binmapr documentation built on Oct. 30, 2019, 12:14 p.m.