You are currently browsing the category archive for the ‘RStudio IDE’ category.

We’re excited to announce a new release of Packrat, a tool for making R projects more isolated and reproducible by managing their package dependencies.

This release brings a number of exciting features to Packrat that significantly improve the user experience:

  • Automatic snapshots ensure that new packages installed in your project library are automatically tracked by Packrat.
  • Bundle and share your projects with packrat::bundle() and packrat::unbundle() — whether you want to freeze an analysis, or exchange it for collaboration with colleagues.
  • Packrat mode can now be turned on and off at will, allowing you to navigate between different Packrat projects in a single R session. Use packrat::on() to activate Packrat in the current directory, and packrat::off() to turn it off.
  • Local repositories (ie, directories containing R package sources) can now be specified for projects, allowing local source packages to be used in a Packrat project alongside CRAN, BioConductor and GitHub packages (see this and more with ?"packrat-options").

In addition, Packrat is now tightly integrated with the RStudio IDE, making it easier to manage project dependencies than ever. Download today’s RStudio IDE 0.98.978 release and try it out!

Packrat RStudio package pane integration

You can install the latest version of Packrat from GitHub with:

    devtools::install_github("rstudio/packrat")

Packrat will be coming to CRAN soon as well.

If you try it, we’d love to get your feedback. Leave a comment here or post in the packrat-discuss Google group.

 

The RStudio team recently rolled out new capabilities in RStudio, shiny, ggvis, dplyr, knitr, R Markdown, and packrat. The “Essential Tools for Data Science with R” free webinar series is the perfect place to learn more about the power of these R packages from the authors themselves.

Click to learn more and register for one or more webinar sessions. You must register for each separately. If you miss a live webinar or want to review them, recorded versions will be available to registrants within 30 days.

The Grammar and Graphics of Data Science
Live! Wednesday, July 30 at 11am Eastern Time US  Click to register

  • dplyr: a grammar of data manipulation – Hadley Wickham
  • ggvis: Interactive graphics in R – Winston Chang

Reproducible Reporting 
Live! Wednesday, August 13 at 11am Eastern Time US  Click to register

  • The Next Generation of R Markdown – Jeff Allen
  • Knitr Ninja – Yihui Xie
  • Packrat – A Dependency Management System for R – J.J. Allaire & Kevin Ushey

Interactive Reporting
Live! Wednesday, September 3 at 11am Eastern Time US  Click to register

  • Embedding Shiny Apps in R Markdown documents – Garrett Grolemund
  • Shiny: R made interactive – Joe Cheng

 

Today we’re very pleased to announce a new version of RStudio (v0.98.932) which is available for download now. New features in this release include:

  • A next generation implementation of R Markdown with a raft of new features including support for HTML, PDF, and Word output, many new options for customizing document appearance, and the ability to create presentations (Beamer or HTML5).
  • Interactive Documents (Shiny meets R Markdown). Readers can now change the parameters underlying your analysis and see the results immediately. Interactive Documents make it easier than ever to use Shiny!
  • Shareable notebooks from R scripts. Notebooks include all R code and generated output, and can be rendered in HTML, PDF, and Word formats.
  • Enhanced debugging including support for the new R 3.1 debugging commands to step into function calls and finish the current loop or function.
  • Various source editor enhancements including new syntax highlighting modes for XML, YAML, SQL, Python, and shell scripts. You can also execute Python and shell scripts directly from the editor using Ctrl+Shift+Enter.
  • Integrated tools for Shiny development including the ability to run applications within an IDE pane as well as Run/Reload applications with a keyboard shortcut (Ctrl+Shift+Enter).
  • A new devtools mode for package development (uses devtools for check, document, test, build, etc.)
  • Contextual Git/SVN menu that enables quick access to per-file revision history and selection-aware View/Blame for projects hosted on GitHub.
  • Fast lookup of shortcuts using the new keyboard shortcut quick-reference card (Alt+Shift+K)

See the release notes for a full list of what’s changed and see Yihui Xie’s post on R Markdown v2 for more on what’s new there.

We’ll be posting additional articles over the next few days that describe the new features in more depth. In the meantime we hope you download the new version and as always let us know how it’s working and what else you’d like to see.

We’re pleased to announce that the final version of RStudio v0.98 is available for download now. Highlights of the new release include:

  • An interactive debugger for R that is tightly integrated with base R debugging tools (browser, recover, etc.)
  • Numerous improvements to the Workspace pane (which is now called the Environment pane).
  • R Presentations for easy authoring of HTML5 presentations that include R code, output, and graphics.
  • A new Viewer pane for displaying local web content (e.g. graphical output from packages like googleVis).
  • Additional support for developing and running Shiny web applications.
  • Substantially improved UI performance on Mac OS X.
  • Professional Edition of RStudio Server with many new capabilities for enterprise deployment.

There are also lots of smaller improvements and bug fixes across the product, check out the release notes for full details.

Debugging Tools

The feature we’re most excited about is the addition of a full interactive debugger to the IDE. Noteworthy capabilities of the debugger include:

  • Setting breakpoints within the source editor, both inside and outside functions
  • Stepping through code line by line
  • Inspecting object values and the call stack during debugging
  • An error inspector for quick access to tracebacks and the debugger after runtime errors
  • Tight integration with traditional R debugging tools, such as browser() and debug()

Here’s a screenshot of the IDE after hitting an editor breakpoint:

RStudioDebugger

For more details on how to take advantage of the new debugging tools, see Debugging with RStudio.

Environment Pane

The Workspace pane is now called the Environment pane and has numerous improvements, including:

  • Browse any environment on the search path
  • Filtering by name/value
  • Expand lists, data frames, and S4 objects inline
  • Use str() to display object values
  • Optional grid view sortable by various attributes
  • Many other small correctness and robustness enhancements

R Presentations

R Presentations enable easy authoring of HTML5 presentations. R Presentations are based on R Markdown, and include the following features:

  • Easy authoring of HTML5 presentations based on R Markdown
  • Extensive support for authoring and previewing inside the IDE
  • Many options for customizing layout and appearance
  • Publishing as either a standalone HTML file or to RPubs

Here’s a screenshot showing a simple presentation being authored and previewed within the IDE:

RPresentations

For more details see the documentation on Authoring R Presentations.

Viewer Pane

RStudio now includes a Viewer pane that can be used to view local web content. This includes both static web content or even a local web application created using ShinyRook, or OpenCPU. This is especially useful for packages that have R bindings to Javascript data visualization libraries.

The googleVis and rCharts packages have already been updated to take advantage of the Viewer pane. Here’s a screenshot of the googleVis integration:

googleVis

We’re hopeful that there will be many more compelling uses of the Viewer. For more details see the article Extending RStudio with the Viewer Pane.

Shiny Integration

We’ve added a number of features to support development of Shiny web applications, including:

  • The ability to develop and run Shiny applications on RStudio Server (localhost and websocket proxying is handled automatically)
  • Running Shiny applications within an IDE pane (see the discussion of the Viewer pane below for details)
  • Create a new Shiny application from within the New Project dialog
  • Debugging of Shiny applications using the new RStudio debugging tools.

Mac UI Framework

In RStudio v0.98 we also migrated our Mac WebKit engine from a cross-platform framework (Qt) to Cocoa. The original motivation for this was compatibility problems between Qt and OS X Mavericks, but as it turned out the move to Cocoa WebKit yielded substantially faster editor, scrolling, layout, and graphics performance across the board. If you are a Mac user you’ll find everything about the product snappier in v0.98.

In the next major version of RStudio we’re hoping to make comparable improvements in performance on both Linux and Windows by using a more modern WebKit on those platforms as well.

RStudio Server Professional Edition

Over the years we’ve gotten lots of feedback from larger organizations deploying RStudio Server on the features they’d like to see for production deployments of the server. With RStudio v0.98 we’re introducing a new Professional Edition of RStudio Server that incorporates much of this feedback. Highlights include:

  • An administrative dashboard that provides insight into active sessions, server health, and monitoring of system-wide and per-user performance and resource metrics.
  • Authentication using system accounts, ActiveDirectory, LDAP, or Google Accounts.
  • Full support for PAM (including PAM sessions for dynamically provisioning user resources).
  • Ability to establish per-user or per-group CPU priorities and memory limits.
  • HTTP enhancements including support for SSL and keep-alive for improved performance.
  • Ability to restrict access to the server by IP.
  • Customizable server health checks.
  • Suspend, terminate, or assume control of user sessions.
  • Impersonate users for assistance and troubleshooting.

The RStudio Server product page has full details on the Professional Edition, and an evaluation version of the server is also available for download.

New Support Site

With this release we’re also introducing a brand new support and documentation website, please visit us there with questions, feedback, as well as what other improvements you’d like to see in the product.

When OS X Mavericks was released last month we were very disappointed to discover a compatibility issue between Qt (our cross-platform user interface toolkit) and OS X Mavericks that resulted in extremely poor graphics performance.

We now have an updated preview version of RStudio for OS X (v0.98.475) that not only overcomes these issues, but also improves editor, scrolling, and layout performance across the board on OS X (more details below if you are curious):

http://www.rstudio.com/ide/download/preview

We were initially optimistic that we could patch Qt to overcome the problems but even with some help from Digia (the organization behind Qt) we never got acceptable performance. Running out of viable options based on Qt, we decided to bypass Qt entirely by implementing the RStudio desktop frame as a native Cocoa application.

OS X Mavericks issues aside, we are thrilled with the result of using Cocoa rather than a cross-platform toolkit. RStudio desktop uses WebKit to render its user-interface, and the Cocoa WebKit Framework is substantially faster than the one in Qt.

Please try out the updated preview and let us know if you encounter any issues or problems on our support forum. For those that prefer to wait for the final release of v0.98 we expect that to happen sometime during the next couple of weeks.

UPDATERStudio OS X Mavericks Issues Resolved

This post is now out of date (see link above for information on getting a version of RStudio that works with OS X Mavericks).


Today Apple released OS X 10.9 “Mavericks”. If you are a Mac user and considering updating to the new OS  there are some RStudio compatibility issues to consider before you update.

As a result of a problem between Mavericks and the user interface toolkit underlying RStudio (Qt) the RStudio IDE is very slow in painting and user interactions  when running under Mavericks. We are following up with both Qt and Apple on resolving the compatibility issue. In the meantime there is a workaround available in the v0.98.443 release of RStudio that can be downloaded here:

http://www.rstudio.com/ide/download/preview

This version of RStudio detects when it is running on OS X Mavericks and in that case bypasses the use of Qt. Rather, a version of RStudio Server is run locally and connected to by a special RStudioIDE browser window. There are several differences you’ll notice when running in this mode:

  1. Only one instance of RStudio can be run at a time.
  2. The Mac native menubar is not used. Rather, the main menu appears inside the RStudio frame.
  3. Mac native file open and save dialogs are not used. Rather, internal versions of the dialogs are used.
  4. Finder file associations activate RStudio however don’t open the targeted file(s).
  5. The copy plot to clipboard function is not available.
  6. During a shutdown of Mac OS X when RStudio is running the current project’s Workspace is not saved automatically (however source files are).

We’re hoping that the underlying problem in OS X 10.9 is resolved in a future update or alternatively the Qt toolkit is updated to address the issue. If and when that occurs we’ll release a new version of RStudio that restores the previous RStudio behavior on OS X 10.9.

We’re very pleased to announce that a preview release of RStudio IDE v0.98 is available for download now. Major highlights of the new release include debugging tools, many improvements to environment/workspace browsing, and a new way to create HTML5 presentations using R Markdown. As usual there are also many small improvements and bug fixes. We’ll talk about some of the more interesting new features below, otherwise check out the release notes for full details.

Debugging Tools

We’ve done lots of work to add R debugging tools to the IDE, including:

  • Setting breakpoints within the source editor, both inside and outside functions
  • Stepping through code line by line
  • Inspecting object values and the call stack during debugging
  • An error inspector for quick access to tracebacks and the debugger after runtime errors
  • Tight integration with traditional R debugging tools, such as browser() and debug()

Here’s a screenshot of the IDE after hitting an editor breakpoint:

RStudioDebugger

Note that execution is stopped at the specified breakpoint, the environment is updated to show the objects within the context where execution was stopped, and commands for line by line stepping, continuing, and aborting the debug session appear in the console.

For more details on how to take advantage of the new tools, see Debugging with RStudio.

R Presentations

R Presentations enable easy authoring of HTML5 presentations. R Presentations are based on R Markdown, and include the following features:

  • Easy authoring of HTML5 presentations based on R Markdown
  • Extensive support for authoring and previewing inside the IDE
  • Many options for customizing layout and appearance
  • Publishing as either a standalone HTML file or to RPubs

Here’s a screenshot showing a simple presentation being authored and previewed within the IDE:

RPresentations

For more details see the documentation on Authoring R Presentations.

RStudio Server Pro

With RStudio v0.98 we’ve added a new Professional Edition of RStudio Server.  New features in RStudio Server Pro include:

  • An administrative dashboard that provides insight into active sessions, server health, and monitoring of system-wide and per-user performance and resource metrics.
  • Authentication using system accounts, ActiveDirectory, LDAP, or Google Accounts.
  • Full support for PAM (including PAM sessions for dynamically provisioning user resources).
  • Ability to establish per-user or per-group CPU priorities and memory limits.
  • HTTP enhancements including support for SSL and keep-alive for improved performance.
  • Ability to restrict access to the server by IP.
  • Customizable server health checks.
  • Suspend, terminate, or assume control of user sessions.
  • Impersonate users for assistance and troubleshooting.

The Professional Edition also includes priority support and a commercial license. You can get more details as well as download a free 45-day evaluation version from the RStudio Server Professional Preview page.

What’s Next

The preview release is feature complete and we expect to release the final version of v0.98 during the next few weeks. After that we’ll be focusing on adding features to make it easier to develop and deploy Shiny web applications and expect another release with those features before the end of the year.

Earlier this month a new version of the Rcpp package by Dirk Eddelbuettel and Romain François  was released to CRAN and today we’re excited to announce a new version of RStudio that integrates tightly with Rcpp.

First though more about some exciting new features in Rcpp 0.10.1. This release includes Rcpp attributes, which are simple annotations that you add to C++ source files to streamline calling C++ from R.  This makes it possible to write C++ functions and simply source them into R just as you’d source an R script. Here’s an example:

#include <Rcpp.h>
using namespace Rcpp;

// [[Rcpp::export]]
NumericMatrix gibbs(int N, int thin) {

   NumericMatrix mat(N, 2);
   double x = 0, y = 0;

   RNGScope scope;
   for(int i = 0; i < N; i++) {
      for(int j = 0; j < thin; j++) {
         x = R::rgamma(3.0, 1.0 / (y * y + 4));
         y = R::rnorm(1.0 / (x + 1), 1.0 / sqrt(2 * x + 2));
      }
      mat(i, 0) = x;
      mat(i, 1) = y;
   }

   return(mat);
}

By annotating the gibbs function with the Rcpp::export attribute, we indicate we’d like that function to be callable from R. As a result we can now call the function like this:

sourceCpp("gibbs.cpp")
gibbs(100, 10)

Thanks to the abstractions provided by Rcpp, the code implementing gibbs in C++ is nearly identical to the code you’d write in R, but runs 20 times faster.

The sourceCpp function makes it much easier to use C++ within interactive R sessions. In the new version of RStudio we did a few things to support this workflow. Here’s a screenshot showing the RStudio C++ editing mode:

In RStudio you can now source a C++ file in the same way as an R script, using the source button on the toolbar or Cmd+Shift+Enter. If errors occur during compilation then RStudio parses the GCC error log and presents the errors as a navigable list.

When using sourceCpp it’s also possible to embed R code within a C++ source file using a special block comment. RStudio treats this code as an R code chunk (similar to Sweave or R Markdown code chunks):

RStudio also includes extensive support for package development with Rcpp. For more details see the Using Rcpp with RStudio document on our website.

Note that if you want to try out the new features be sure you are running RStudio v0.97.237 as well as the very latest version of Rcpp (0.10.1) .

Today a new version of RStudio (v0.97) is available for download from our website.  The principal focus of this release was creating comprehensive tools for R package development. We also implemented many other frequently requested enhancements including a new Vim editing mode and a much improved Find and Replace pane. Here’s a summary of what’s new in the release:

Package Development

  • A new Build tab with package development commands and a view of build output and errors
  • Build and Reload command that rebuilds the package and reloads it in a fresh R session
  • Create a new package using existing source files via New Project
  • R documentation tools including previewing, spell-checking, and Roxygen aware editing
  • Integration with devtools package development functions
  • Support for Rcpp including syntax highlighting for C/C++ and gcc error navigation

Source Editor

  • Vim editing mode
  • Tomorrow suite of editor themes
  • Find and replace: incremental search, find/replace in selection, and backwards find
  • Auto-indenting: improved intelligence and new options to customize indenting behavior
  • New options: show whitespace, show indent guides, non-blinking cursor, focus console after executing code

More

  • New Restart R and Terminate R commands
  • More intelligent console history navigation with up/down arrow keys
  • View plots within a separate window/monitor.
  • Ability to set a global UI zoom-level
  • RStudio CRAN mirror (via Amazon CloudFront) for fast package downloads

There are also many more small improvements and bug fixes. Check out the v0.97 release notes for details on all of the changes.

There’s an updated release of RStudio v0.96 available that includes some small enhancements and bugfixes, including:

  • Comment/uncomment for Sweave and LaTeX
  • Additional in-product documentation for R Markdown
  • Offline support for MathJax previews
  • More flexible handling of MathJax inline equations

The release notes include a full list all of the changes.

We’ve also published some additional documentation on using the new code folding and code sections features.

The updated version is available for download from our site now.

Follow

Get every new post delivered to your Inbox.

Join 689 other followers