Install the dependencies
install.packages("jsonlite") install.packages("httr") install.packages("base64enc")
To install directly from Github, use devtools
:
install.packages("devtools") library(devtools) install_github("sdgamboa/omicidxClientR")
library(dplyr)
Create a client object (api
):
basePath <- "https://api.omicidx.cancerdatasci.org" client <- ApiClient$new(basePath = basePath) api <- SRAApi$new(apiClient = client)
Example 1:
result1 <- api$RunsForStudySraStudiesAccessionRunsGet(accession = "SRP114847", size = 10) df1 <- result1$hits
Example 2:
result2 <- api$StudiesSraStudiesGet() hit_list <- result2$toJSON()$hits df2 <- bind_rows(hit_list)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.