load a list of SummarizedExperiment
s from an extracted RefineBio download
Source: R/rb_dataset_loader.R
extract_local_dataset.Rd
The download directory from RefineBio is a zip file containing a folder of
experiments. This function will load the experiments from the extracted
zip file and return a list of SummarizedExperiment
s. In the case of a
single experiment, the list will contain a single element.
Value
A list of SummarizedExperiment
s representing the
experiments in the RefineBio downloaded dataset.
Examples
# load the SummarizedExperiment package
# We'll need it later.
suppressPackageStartupMessages(library(SummarizedExperiment))
# use an example datastore
datastore_path <- datastore_example_path()
# Get the first dataset from the datastore
example_dataset <- datastore_datasets(datastore_path)[1]
# Get the path to the dataset
example_dataset_path <- file.path(datastore_path, example_dataset)
# Load the dataset
example_se_list <- extract_local_dataset(example_dataset_path)
#> Error in extract_local_dataset(example_dataset_path): Could not find metadata file in download directory.
# Get the first experiment
example_se <- example_se_list[[1]]
#> Error in eval(expr, envir, enclos): object 'example_se_list' not found
example_se
#> Error in eval(expr, envir, enclos): object 'example_se' not found
# Get the first experiment's metadata
str(metadata(example_se))
#> Error in h(simpleError(msg, call)): error in evaluating the argument 'x' in selecting a method for function 'metadata': object 'example_se' not found