simulateSpectra | R Documentation |
Generate simulated data using zero-inflated Poisson model
simulateSpectra( W = NULL, pzero = 0, nmut = 100, h, N = 10, dilute.ultra = FALSE, min.mut = 1, distr = "pois", vmr = 2, Ntry = 10000 )
W |
Input signature matrix |
pzero |
Proportion of extra zero counts (scalar) |
nmut |
Mean number of mutations per sample (scalar) |
h |
Vector of average proportion of mutations in each process;
length equal to the number of columns in |
N |
No. of samples |
dilute.ultra |
Dipute ultra-mutated samples to reduce bias |
min.mut |
Minimum mutation load |
distr |
Underlying distribution of exposure counts;
|
vmr |
Variance to mean ratio of negative binomial. |
See Omichessan et al. DOI: 10.1371/journal.pone.0221235
List of components X
: simulated mutation counts;
W
, H
: signature and exposure matrices.
set.seed(135) K <- 5 # no. of processes W <- t(gtools::rdirichlet(n = K, alpha = rep(1, 96))) rownames(W) <- trinucleotides() h <- gtools::rdirichlet(n = 1, alpha = rep(5, K)) x <- simulateSpectra(W = W, h = h, N = 100) h <- read.table(system.file('extdata', 'hmean_breast_lung_skin_pancr.txt', package = 'tempoSig'), header = TRUE, sep = '\t') h <- t(h)['Breast',] x <- simulateSpectra(h = h, N = 100)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.