Skip to contents

Retrieves all the files belonging to the given project_id for display on the Downloads Page

GTEx Portal API documentation

Usage

get_downloads_page_data(project_id = "adult-gtex")

Arguments

project_id

String. Options: "gtex", "adult-gtex", "egtex".

Value

A Tibble

Details

Note: The GTEx Portal API documentation states "GTEx currently has one project available: gtex". However, project_id values "adult-gtex" and "egtex" both return results, whereas "gtex" does not (see examples).

Examples

# \dontrun{
 # "adult-gtex" (default `project_id` value) and "egtex" both return results
 get_downloads_page_data()
#> # A tibble: 9 × 6
#>   name                         displayName description order parent children    
#>   <chr>                        <chr>       <chr>       <int> <chr>  <list>      
#> 1 gs://adult-gtex/bulk-gex/    Bulk tissu… ""              1 gs://… <named list>
#> 2 gs://adult-gtex/bulk-qtl/    QTL         ""              2 gs://… <named list>
#> 3 gs://adult-gtex/single-cell/ Single cell ""              3 gs://… <named list>
#> 4 gs://adult-gtex/long-read-d… Long read … "Long Read…     4 gs://… <named list>
#> 5 gs://adult-gtex/haplotype-e… Haplotype … "Haplotype…     5 gs://… <named list>
#> 6 gs://adult-gtex/variants/    Variants    ""              6 gs://… <named list>
#> 7 gs://adult-gtex/references/  Reference   ""              7 gs://… <named list>
#> 8 gs://adult-gtex/annotations/ Metadata    ""              8 gs://… <named list>
#> 9 gs://adult-gtex/additional_… Additional… ""              9 gs://… <named list>
 egtex <- get_downloads_page_data("egtex")
 egtex
#> # A tibble: 3 × 6
#>   name                    displayName description      order parent children    
#>   <chr>                   <chr>       <chr>            <int> <chr>  <list>      
#> 1 gs://egtex/methylation/ Methylation ""                   1 gs://… <named list>
#> 2 gs://egtex/proteomics/  Proteomics  "Protein and RN…     2 gs://… <named list>
#> 3 gs://egtex/telomeres/   Telomeres   "Relative telom…     3 gs://… <named list>

 # ..."gtex" does not
 get_downloads_page_data("gtex")
#> # A tibble: 0 × 0

 # get details for whole blood methylation data, including download URL
 purrr::pluck(
   egtex$children,
   1,
   "folders",
   "Methylation - EPIC Array",
   "children",
   "folders",
   "mQTLs",
   "children",
   "files",
   "WholeBlood.mQTLs.regular.txt.gz"
 )
#> $displayName
#> [1] "WholeBlood.mQTLs.regular.txt.gz"
#> 
#> $description
#> [1] ""
#> 
#> $fileSize
#> [1] 43461408219
#> 
#> $url
#> [1] "https://storage.googleapis.com/egtex/methylation/epic-arrays/mQTLs/WholeBlood.mQTLs.regular.txt.gz"
#> 
#> $order
#> [1] 27
#> 
#> $parent
#> [1] "gs://egtex/methylation/epic-arrays/mQTLs/"
#> 
# }