Description Usage Arguments Details Value See Also Examples
Simulates counts according to a Dirichlet-multinomial model, according to model parameters given by object dm.fit.
1 2 | sim.groups(dm.fit, Nshuffle = 15, params = list(mu1 = 300, sd1 = 50, N1 =
20, mu2 = 300, sd2 = 50, N2 = 20))
|
dm.fit |
|
Nshuffle |
number of features to shuffle |
params |
list of parameters describing the number the mean and standard deviation of library sizes for case and control samples, as well as the number of samples of each |
Simulates two sets of counts (case/control), where one set is generated
according to the parameters in object dm.fit
, and and the second set is
generated such that Nshuffle
number of high abundance features are
shuffled with Nshuffle
number of low abundance features, generating a final
data set with a large number of differences between case and control samples for
large enough Nshuffle
. Requires package dirmult
to generate samples.
List with objects counts
, i.spike
, groups
: a counts table, feature
names which have been shuffled, and group membership (case/control), respectively
sim.counts
for simulation of a single group of samples
1 2 3 4 5 6 7 8 9 10 11 12 13 | library(HMP)
library(dirmult)
S <- sim.groups(dm.fit.eso)
S$eb <- eb.pseudo(S$counts)
S$gt <- gt.pseudo(S$counts)
round(head(S$eb),4)
S <- sim.groups(dm.fit.lung, Nshuffle = 50,
params = list(mu1 = 2000, sd1 = 200, N1 = 20,
mu2 = 6000, sd2 = 600, N2 = 20))
S$eb <- eb.pseudo(S$counts)
S$gt <- gt.pseudo(S$counts)
round(head(S$gt),4)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.