retrieve_sra_metadata: Retrieve metadata for an SRA accession

Description Usage Arguments Value Note Examples

Description

This function uses the EBI's or the NCBI's REST APIs to retrieve information about SRA data. Study accessions (ERP, SRP, DRP, PRJ prefixes), experiment accessions (ERX, SRX, DRX prefixes), sample accessions (ERS, SRS, DRS, SAM prefixes) and run accessions (ERR, SRR, DRR prefixes) can be supplied. For more information see http://www.ebi.ac.uk/ena/browse/file-reports

Usage

1
retrieve_sra_metadata(x, from = c("ena", "ncbi"))

Arguments

x

SRA identifier

from

Scalar character, specifying either ncbi or ena as the source database

Value

A tbl_df data.frame

Note

The output data.frame will be different for the two source databases.

Examples

1
2
3
4
5
6
7
if (interactive()) {
   # retrieve study annotations
   retrieve_sra_metadata("SRP066489")
   # paired-end samples
   retrieve_sra_metadata("PRJEB2054", "ena") %>%
   dplyr::filter(sample_accession == "SAMEA728920")
}

denalitherapeutics/archs4 documentation built on May 17, 2019, 1:29 p.m.