Skip to contents

Build SummarizedExperiment using a single sfaira entry ID

Usage

dataset_sfaira(
  sfaira_id,
  sfaira_setup,
  name = "SimBu_dataset",
  spike_in_col = NULL,
  additional_cols = NULL,
  force = FALSE,
  filter_genes = TRUE,
  variance_cutoff = 0,
  type_abundance_cutoff = 0,
  scale_tpm = TRUE
)

Arguments

sfaira_id

(mandatory) ID of a sfaira dataset

sfaira_setup

(mandatory) the sfaira setup; given by setup_sfaira

name

name of the dataset; will be used for new unique IDs of cells

spike_in_col

which column in annotation contains information on spike_in counts, which can be used to re-scale counts

additional_cols

list of column names in annotation, that should be stored as well in dataset object

force

boolean, if TRUE, datasets without annotation will be downloaded, FALSE otherwise (default)

filter_genes

boolean, if TRUE, removes all genes with 0 expression over all samples & genes with variance below variance_cutoff

variance_cutoff

numeric, is only applied if filter_genes is TRUE: removes all genes with variance below the chosen cutoff

type_abundance_cutoff

numeric, remove all cells, whose cell-type appears less then the given value. This removes low abundant cell-types

scale_tpm

boolean, if TRUE (default) the cells in tpm_matrix will be scaled to sum up to 1e6

Value

dataset object

Examples

# \donttest{
setup_list <- SimBu::setup_sfaira(tempdir())
ds <- SimBu::dataset_sfaira(
  sfaira_id = "homosapiens_lungparenchyma_2019_10x3v2_madissoon_001_10.1186/s13059-019-1906-x",
  sfaira_setup = setup_list,
  name = "test_dataset"
)
# }