View source: R/exportSCEtoAnndata.R
exportSCEtoAnnData | R Documentation |
Writes all assays, colData, rowData, reducedDims, and altExps objects in a SingleCellExperiment to a Python annData object in the .h5ad format All parameters of Anndata.write_h5ad function (https://icb-anndata.readthedocs-hosted.com/en/stable/anndata.AnnData.write_h5ad.html) are available as parameters to this export function and set to defaults. Defaults can be overridden at function call.
exportSCEtoAnnData(
sce,
useAssay = "counts",
outputDir = "./",
prefix = "sample",
overwrite = TRUE,
compression = c("gzip", "lzf", "None"),
compressionOpts = NULL,
forceDense = FALSE
)
sce |
SingleCellExperiment R object to be exported. |
useAssay |
Character. The name of assay of
interests that will be set as the primary matrix of the output AnnData.
Default |
outputDir |
Path to the directory where .h5ad outputs will be written. Default is the current working directory. |
prefix |
Prefix to use for the name of the output file. Default |
overwrite |
Boolean. Default |
compression |
If output file compression is required, this variable accepts
'gzip', 'lzf' or "None" as inputs. Default |
compressionOpts |
Integer. Sets the compression level |
forceDense |
Default |
Generates a Python anndata object containing data from inSCE
.
data(sce_chcl, package = "scds")
## Not run:
exportSCEtoAnnData(sce=sce_chcl, compression="gzip")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.