Description Usage Arguments Value
View source: R/simple_moi_simulation.R
Generate read count data in support of SNVs partioned by mixtures of clones within a host. This is done by setting true clonal mixture proportions and the underlying sampling probabilities for each clone. Then a random sample of underlying SNV probabilities is sampled from either a rbeta or rtexp distrubition with given parameters and read counts are generated by bionimial conditonal on the underlying SNV probability with the clone sampling probabilities.
1 2 3 4 5 6 7 8 9 | simulateMOI(
n.samples,
n.snps,
moi,
mean_coverage,
error_coverage,
pi.true = NULL,
mu.true = NULL
)
|
n.samples |
number of infected hosts in population |
n.snps |
number of SNPs observed |
moi |
number of clonal infections |
mean_coverage |
average coverage of reads |
error_coverage |
deviation in coverage of reads |
pi.true |
optional matrix of true mixture proportions |
mu.true |
optional matrix of true mixture components |
A list containing the following elements pi.true an n.samples by moi matrix containing true clonal proportions mu.true an n.samplps by moi matrix containing true genotype proportions aaf an n.snps vector of under SNV probabilities read.counts an n.samples by n.snps matrix containing read counts supporting each SNV error.counts an n.samples by n.snps matrix containing number of error reads
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.