downloadStudy | R Documentation |
Note that these functions should be used when a particular
study is not currently available as a MultiAssayExperiment
representation. Otherwise, use cBioDataPack
. Provide a cancer_study_id
from getStudies
and retrieve the study tarball from the cBio Genomics
Portal. These functions are used by cBioDataPack
under the hood to
download,untar, and load the tarball datasets with caching. As stated in
?cBioDataPack
, not all studies are currently working as
MultiAssayExperiment
objects. As of July 2020, about ~80% of datasets can
be successfully imported into the MultiAssayExperiment
data class. Please
open an issue if you would like the team to prioritize a study. You may
also check getStudies(buildReport = TRUE)$pack_build
for the current
status.
downloadStudy(
cancer_study_id,
use_cache = TRUE,
force = FALSE,
url_location = getOption("cBio_URL", .url_location),
ask = interactive()
)
untarStudy(cancer_study_file, exdir = tempdir())
loadStudy(
filepath,
names.field = c("Hugo_Symbol", "Entrez_Gene_Id", "Gene", "Composite.Element.REF"),
cleanup = TRUE
)
cancer_study_id |
|
use_cache |
|
force |
|
url_location |
|
ask |
|
cancer_study_file |
|
exdir |
|
filepath |
|
names.field |
|
cleanup |
|
When attempting to load a dataset using loadStudy
, note that the
cleanup
argument is set to TRUE
by default. Change the argument to
FALSE
if you would like to keep the untarred data in the exdir
location. downloadStudy
and untarStudy
are not affected by this change.
The tarball of the downloaded data is cached via BiocFileCache
when
use_cache
is TRUE
.
downloadStudy - The file location of the data tarball
untarStudy - The directory location of the contents
loadStudy - A MultiAssayExperiment-class object
cBioDataPack, MultiAssayExperiment
acc_file <- downloadStudy("acc_tcga")
acc_file
file_dir <- untarStudy(acc_file, tempdir())
file_dir
loadStudy(file_dir)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.