sevenbridges2

R-CMD-check

Overview

sevenbridges2 is an API client package that provides an interface for the Seven Bridges Platform (US, EU, China), Cancer Genomics Cloud, CAVATICA, and BioData Catalyst Powered by Seven Bridges public APIs.

The Seven Bridges Platform is a cloud-based environment for conducting bioinformatics analysis. It is a central hub for teams to store, analyze, and jointly interpret their bioinformatic data. The Platform co-locates analysis pipelines alongside the largest genomic datasets to optimize processing, allocating storage, and compute resources on demand.

The Cancer Genomics Cloud (CGC), powered by Seven Bridges, is also a cloud-based computation environment. It was built as one of three pilot systems funded by the National Cancer Institute to explore the paradigm of colocalizing massive genomics datasets, like The Cancer Genomics Atlas (TCGA), alongside secure and scalable computational resources to analyze them. The CGC makes more than a petabyte of multi-dimensional data available immediately to authorized researchers. You can add your data to analyze alongside TCGA using predefined analytical workflows or your own tools.

CAVATICA, powered by Seven Bridges, is a data analysis and sharing platform designed to accelerate discovery in a scalable, cloud-based compute environment where data, results, and workflows are shared among the world’s research community. CAVATICA is built in collaboration with the Children Hospital of Philadelphia and it is focused on pediatric data.

The BioData Catalyst, powered by Seven Bridges, is a computational environment on the cloud. It hosts several genomic datasets, alongside tools for analyzing genomic information, and features for collaboration.

Table of Contents

Installation

Easiest way is to install package from CRAN:

# Install package from CRAN:
install.packages("sevenbridges2")

Development version

To get a bug fix or to use a feature from the development version, you can install the development version of sevenbridges2 from GitHub.

# install.packages("devtools")
devtools::install_github("sbg/sevenbridges2@develop")

Features

The sevenbridges2 package includes the following features:

Flexible Authentication Methods

Multiple authentication methods support.

Direct authentication

To use direct authentication, users need to specify one of platform or url, with the corresponding token. Examples of direct authentication:

# Direct authentication with setting platform parameter
a <- Auth$new(
  token = "<your_token>",
  platform = "aws-us"
)

Authentication via system environment variables

To set the two environment variables in your system, you could use the function sbg_set_env(). For example:

# Set environment variables
sevenbridges2:::sbg_set_env(
  url = "https://cgc-api.sbgenomics.com/v2",
  token = "<your_token>"
)

# Authenticate using environment variables
a <- Auth$new(from = "env")

Authentication via a user configuration file

You collect and manage your credentials for multiple accounts across various Seven Bridges environments:

# Authenticate using file configuration and specific profile
a <- Auth$new(from = "file", profile_name = "aws-us-<username>")

Please check vignette("Authentication_and_Billing", package = "sevenbridges2") for technical details about all available authentication methods.

Complete API R Client

A complete API R client with a user-friendly, object-oriented API with printing and support operations for API requests relating to users, billing, projects, files, apps, and tasks. Short examples are also included, as shown below:

# Get a project by pattern-matching its name
p <- a$projects$query("demo")

# Get a project by its id
p <- a$project$get(id = "username/demo")

# List files in project
p$list_files()

# Create upload job and set destination project
upload_job <- a$upload(
  path = "/path/to/your/file.txt",
  project = destination_project,
  overwrite = TRUE,
  init = TRUE
)

Please check vignette("quickstart", package = "sevenbridges2") for technical details about all available API methods and features.

Cross Environment Support

Cross-platform support for Seven Bridges environments, such as Seven Bridges Platform (US, EU, China), Cancer Genomics Cloud, CAVATICA, and BioData Catalyst Powered by Seven Bridges on either Amazon Web Services or Google Cloud Platform.

Documentation

Docs website

Contribute

Please file bug reports/feature requests on the issue page, or create pull requests here.

Contributors should sign the Seven Bridges Contributor Agreement before submitting a pull request.

© 2024 Velsera, Inc. All rights reserved.

This project is licensed under the terms of the Apache License 2.0.

mirror server hosted at Truenetwork, Russian Federation.