This function adds user provided options for simulating RNA-seq data to RNAseq.SimSetup object. The resulting output list object is the input for simulateDE function.
SimSetup(desetup, params, spike=NULL, size.factors='equal', downsample=FALSE, geneset=FALSE)
| desetup | The RNAseq simulation parameters created by |
|---|---|
| params | The negative binomial parameters for simulations. This can be:
(1) The output of |
| spike | The spike-in simulation parameters created by |
| size.factors | Size factors representing sample-specific differences/biases in expected mean values of the NB distribution:
"equal" or "given". The default is "equal", i.e. equal size factor of 1.
If the user defines it as given, the size factors are sampled from the size factors provided by the output of |
| downsample | Drawing the associated dispersions after determining effective mean expressions by size factors. Default is |
| geneset | Sampling with replacement or filling count tables with low magnitude Poisson
when the estimated mean expression vector is shorter than the number of genes to be simulated.
Default is |
A list with the following entries:
The RNAseq simulation parameters.
The distributional parameters for simulations of genes.
The distributional parameters for simulations of spike-ins.
Size factor definition: "equal" means no difference in size factors between samples.
"given" means that the size factors will be randomly drawn from the size factors provided by params.
The user can also provide a list object containing sampling distributions per group (n1 and n2).
Defaul is "equal".
# NOT RUN { ## Setting DE options de.opts <- DESetup(ngenes = 10000, nsims = 25, p.DE = 0.2, pLFC = function(x) sample(c(-1,1), size=x,replace=TRUE)*rgamma(x, 3, 3), p.B=0.1, bLFC = function(x) rnorm(x, mean=0, sd=1.5), bPattern="uncorrelated", sim.seed = 43856) ## Combining DE options with parameters sim.opts <- SimSetup(desetup = de.opts, params = kolodziejczk_param, spike=NULL, size.factors = "equal", downsample = FALSE, geneset = FALSE) # }