dot-pull_data_by_cohort: Function to retrieve data by synapse ID

.pull_data_by_cohortR Documentation

Function to retrieve data by synapse ID

Description

Function to retrieve data by synapse ID

Usage

.pull_data_by_cohort(version_num_df, token, download_location)

Arguments

version_num_df

a dataframe of 'Synapse' IDs

token

a 'Synapse' token

download_location

if 'NULL' (default), data will be returned as a list of dataframes with requested data as list items. Otherwise, specify a folder path to have data automatically downloaded there.

Value

downloaded 'Synapse' data as a list if 'download_location'= 'NULL, or to a local path

Examples



temp_directory <- tempdir()

syn_df <- data.frame(
  cohort = c("NSCLC", "NSCLC"),
  version = c("v2.2-consortium", "v2.0-public"),
  version_num = c("NSCLC_v2.2", "NSCLC_v2.0"),
  download_folder = c(temp_directory, temp_directory),
  df = c("pt_char", "ca_dx_index"),
  synapse_id = c("syn53470868", "syn30350575")
)

.pull_data_by_cohort(
  version_num_df = syn_df,
  token = .get_synapse_token(), download_location = NULL
)

#


AxelitoMartin/GenieBPC documentation built on April 20, 2024, 6:38 a.m.