Description Usage Arguments Details Value Examples
View source: R/SCESet-methods.R
Merge two SCESet objects that have the same features but contain different cells/samples.
1 | mergeSCESet(x, y, fdata_cols = NULL, pdata_cols = NULL)
|
x |
an |
y |
an |
fdata_cols |
a character vector indicating which columns of featureData
of |
pdata_cols |
a character vector indicating which columns of phenoData
of |
Existing cell-cell pairwise distances and feature-feature pairwise distances will not be valid for a merged SCESet
object.
These entries are subsequently set to NULL
in the returned object.
Similarly, new experimentData
will need to be added to the merged object.
If fdata_cols
does not include the definition of feature controls, the control sets may not be defined in the output object.
In such cases, a warning is issued and the undefined control sets are removed from the featureControlInfo
of the merged object.
It is also strongly recommended to recompute all size factors using the merged object, and re-run normalize
before using exprs
.
For arbitrary x
and y
, there is no guarantee that the size factors (and thus exprs
) are comparable across objects.
a merged SCESet
object combining data and metadata from x
and y
1 2 3 4 5 6 7 8 9 10 11 12 13 | data("sc_example_counts")
data("sc_example_cell_info")
pd <- new("AnnotatedDataFrame", data = sc_example_cell_info)
example_sceset <- newSCESet(countData = sc_example_counts, phenoData = pd)
mergeSCESet(example_sceset[, 1:20], example_sceset[, 21:40])
## with specification of columns of fData
example_sceset <- calculateQCMetrics(example_sceset)
mergeSCESet(example_sceset[, 1:20], example_sceset[, 21:40], fdata_cols = c(1, 7))
## with specification of columns of pData
mergeSCESet(example_sceset[, 1:20], example_sceset[, 21:40], pdata_cols = 1:6)
mergeSCESet(example_sceset[, 1:20], example_sceset[, 40], pdata_cols = 3)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.