View source: R/generateCountData.R
generateCountData | R Documentation |
This function can be used to generate counts, e.g., RNA-Sequencing data, for both the classification and clustering purposes.
generateCountData(n, p, K, param, sdsignal = 1, DE = 0.3, allZero.rm = TRUE, tag.samples = FALSE)
n |
number of samples. |
p |
number of variables/features. |
K |
number of classes. |
param |
overdispersion parameter. This parameter is matched with the argument |
sdsignal |
a nonzero numeric value. As |
DE |
a numeric value within the interval [0, 1]. This is the proportion of total number of variables that is significantly different among K classes. The remaining part is assumed to be having no contribution to the discrimination function. |
allZero.rm |
a logical. If TRUE, the columns having all zero cells are dropped. |
tag.samples |
a logical. If TRUE, the row names are automatically generated using a tag for each sample such as "S1", "S2", etc. |
|
count data matrix for training and test set. |
|
class labels for training and test set. |
|
true size factors for training and test set. See Witten (2011) for more information on estimating size factors. |
Dincer Goksuluk
set.seed(2128) counts <- generateCountData(n = 20, p = 10, K = 2, param = 1, sdsignal = 0.5, DE = 0.8, allZero.rm = FALSE, tag.samples = TRUE) head(counts$x)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.