Posit Workbench (RStudio)

Learn how to start RStudio sessions, transfer files, and manage backups in Posit Workbench (RStudio) on the DNAnexus Platform.

Introduction

The Posit Workbench (RStudio) app runs on the DNAnexus Platform. You can use RStudio to run analysis workflows, inspect data, and work in an interactive cloud terminal.

Prerequisites and Availability

Posit Workbench on the DNAnexus Platform is available for organizations that have an existing license agreement with Posit. Before you can launch an RStudio session, you need to request access for your organization.

You do not need to provide a license key. DNAnexus verifies your organization's eligibility directly with Posit during setup.

Request Access for Your Organization

Requesting access to Posit Workbench (RStudio) for your organization is a one-time process that requires coordination between your organization, Posit, and DNAnexus.

  1. Include the following details in your access request:

    • Customer legal entity name: Provide the name that appears in your Posit contract.

    • Organization ID: Provide the org ID, for example org-abcgenomics.

    • Seat admin name: Identify the person who manages seats for Posit Workbench in DNAnexus.

    • Seat admin email: Provide the seat admin's email address.

    • Seat admin DNAnexus username: Provide the seat admin's active DNAnexus account, for example, user-johndoe.

    • Approximate number of expected users: This helps Posit validate seat allocation for your organization.

  2. Send an access request to DNAnexus Support and include all required information.

  3. Wait for DNAnexus to verify eligibility with Posit and enable access for your organization.

Seat Management

Seat limits are enforced at the organization level by the org admin.

  • Org admins can review member limits on the organization member guide.

  • When the member limit is reached, inviting new members is automatically disabled.

  • If a user is removed from the licensing organization, active Posit Workbench sessions for that user are terminated and the seat is freed.

You can also review the seat limit with the organization describe command:

In the command output, the memberLimit field reports the maximum number of members allowed for the organization.

For support with licensing or access, contact DNAnexus Support.

Starting a Session

To create a new workbench environment:

  1. In the DNAnexus Platform > Tools, select Posit Workbench (RStudio).

  2. On the Sessions page, click New Workbench.

  3. (Optional) Enter an environment name.

  4. Select an instance type.

  5. Keep High priority unless you have a specific reason to change it.

  6. Click Start Environment.

Wait until status changes from Initializing to Ready, so you can:

  • Launch the Posit Workbench by selecting the session name or clicking Open.

  • View details, such as estimated price, by opening the Info Panel icon next to New Workbench.

Use the RStudio Environment

Transfer Files with the Terminal

The Terminal tab supports DNAnexus CLI commands for file movement between your project and your active workbench environment.

Upload Results from RStudio to a Project

  1. Open the Terminal tab in RStudio.

  2. Upload a file:

  3. Repeat the command for additional files or provide a directory path.

You can upload multiple files or a full directory in one command.

Download Project Files to RStudio

  1. Open the Terminal tab in RStudio.

  2. List project contents:

  3. Download one or more files or folders:

Downloaded files are placed in your current working directory.

The app has VIEW access to projects you can access and CONTRIBUTE access to the project where the app is running.

The RStudio Terminal runs dx download commands to copy project data into your workbench workspace.

Import Tabular Data into R

After you download CSV or TSV files into your workbench directory, import them in R with standard read functions.

After downloading a CSV file with dx download, use a base R import function in RStudio to load the file into your analysis session.

Read Large Files from /mnt/project

The project where RStudio is running is mounted as read-only at /mnt/project. Use the mount path when you need read-only access and you do not want to copy large files into local workspace storage.

  1. Confirm that your session is running in the target project.

  2. Open files from /mnt/project in your R scripts.

  3. Read only the data ranges you need.

This method reduces local disk usage and can increase API traffic.

Install System Packages

Run package installation commands in the Terminal tab with sudo.

For example, to install wget:

The Terminal supports apt-get commands so you can install required system packages with sudo access.

The workbench environment is temporary. Files and package installations in the worker are removed when the session ends. Upload files you want to keep to your DNAnexus project.

Save and Restore Workspace Data

Use project uploads for individual outputs. Use folder backups when you want a single archive of a working directory.

Back Up a Folder to Your Project

To back up the current folder with default settings:

By default, the backup file name is .Backups/<rstudio_workbench>.<dnanexus-username>.tar.gz.

To back up a specific folder to a specific destination path:

To exclude paths or patterns:

Restore a Folder from a Backup

To restore into the current directory without overwriting local files:

Terminating a Session

You can terminate a session from either of these locations:

  • In the active RStudio environment header, select Terminate.

  • In the Sessions page, open the three-dot menu for a running session and select End environment.

The Sessions page shows the row action menu where you can select End Environment to stop a running session.

Closing the browser does not stop a running session. Compute charges continue until you terminate the environment.

If the job is still running, you can return to the same environment by opening the session URL job-xxxx.dnanexus.cloud.

Last updated

Was this helpful?