Skip to contents

Downloads a 10x Genomics dataset, consisting of 3k cells then performs optional QC and subsetting. Holds subsetted objects in disk, and returns a list with both the matrix and fragments.

Usage

prepare_demo_data(
  directory = NULL,
  filter_qc = TRUE,
  subset = TRUE,
  timeout = 300
)

Arguments

directory

(character) The directory where all the input/output data will be stored. Downloaded intermediates will be stored in subdir intermediates. If NULL, a temporary directory is created.

filter_qc

(bool) Whether to filter both the RNA and ATAC data using QC information.

subset

(bool) Whether to subset to only genes/insertions on chromosome 4 and 11.

timeout

(numeric) Timeout for downloading files in seconds.

Value

(list) A list with the RNA matrix under the name mat, and the ATAC fragments under the name frags.

Details

This function downloads the 10x Genomics PBMC 3k dataset. Filtering using QC information on the fragments and matrix provides cells with at least 1000 reads, 1000 frags, and a minimum tss enrichment of 10. Subsetting provides only genes and insertions on chromosomes 4 and 11. The name of the matrix and fragments folders are demo_mat and demo_frags respectively. Additionally, choosing to qc filter appends a _filtered, and choosing to subset data appends a _subsetted to the name.