bg__mean2disp: Mean to Dispersion

Description Usage Arguments Details Value References Examples

Description

Default function to calculate the negative binomial dispersion parameter given the mean expression of the gene.

Usage

1
	bg__default_mean2disp(mu, coeffs=c(3.967816,-1.855054))

Arguments

mu

mean expression of the gene(s)

coeffs

coefficients of linear regression between log(cv2) and log10(mean expression) for observed data.

Details

Given the coefficients of a linear regression between the natural logarithm of the squared coefficient of variation and log base 10 of mean expression, calculates the dispersion parameter (1/size) of the negative binomial distribution for a given expression level.

Default coefficients were fit to the Buettner at al.[1] single cell mESC data.

Value

the dispersion parameter (1/size) for the (mu,size) paramterization of the rnbinom function.

References

[1] Buettner et al. (2015) Computational analysis of cell-to-cell heterogeneity in single-cell RNA-sequencing data reveals hidden subpopulations of cells. Nature Biotechnology 33 : 155-160.

Examples

1
2
3
4
# mu <- 100
# r <- bg__default_mean2disp(mu)
# n_cells <- 50
# sim <- rnbinom(n_cells, size=1/r, mu=mu)

M3Drop documentation built on Nov. 8, 2020, 5:06 p.m.