Condividi tramite


How to install R Tools for Visual Studio

Applies to: yesVisual Studio noVisual Studio for Mac

Note

This article applies to Visual Studio 2017. If you're looking for the latest Visual Studio documentation, see Visual Studio documentation. We recommend upgrading to the latest version of Visual Studio. Download it here

In this article:

Note

After installing R Tools, you may want to configure Visual Studio for an optimized data scientist layout, as described on the Options article.

Supported versions of Visual Studio

R Tools for Visual Studio (RTVS) is supported on Windows with the Community (free), Professional, and Enterprise editions of both Visual Studio 2017 and Visual Studio 2015 Update 3 (or higher) (direct download).

RTVS is not presently supported on Visual Studio for Mac.

RTVS does not install if you have only the Visual Studio Shell that's included with products such as Visual Studio Test Professional and SQL Server Management Studio. Visual Studio Shell lacks the necessary components for RTVS.

Install RTVS in Visual Studio 2017

  1. Run the Visual Studio installer and select the Modify option (for details, see Modify Visual Studio). If you don't yet have Visual Studio installed, see Install Visual Studio. On Windows 7, be sure that your installer is updated to show Visual Studio 2017 version 15.2 build 26430.12 or later.

  2. Select the Data science and analytical applications workload:

    Data science and analytical applications workload in VS2017

  3. Set any additional options on the right side under the same workload name. By default, this workload includes F# and Python support. For R, minimum requirements are R language support, Runtime support for R development, and Microsoft R client.

RTVS is installed in: %ProgramFiles(x86)%\Microsoft Visual Studio<version><edition>Common7\IDE\Extensions\Microsoft\R Tools for Visual Studio where <version> is typically 2017 and <edition> is Community, Professional, or Enterprise.

Install RTVS in Visual Studio 2015

With Visual Studio 2015, you need to install an R interpreter and the R Tools separately.

Install an R interpreter

RTVS requires a 64-bit installation of R version 3.2.1 or higher from one or more of the following sources:

Microsoft R Open and CRAN R both allow for multiple side-by-side versions. Microsoft R Client, however, supports only one version and always uses the latest one you installed.

Install the R tools

Download the current RTVS for Visual Studio 2015 from https://rtvs.blob.core.windows.net/download/RTVS_2017-12-18.1.exe. RTVS checks for a suitable version of Visual Studio and helps you install an R interpreter if you haven't already.

Note

The standalone RTVS installer works only with Visual Studio 2015; with Visual Studio 2017, install R support through the Data Science and Analytical Applications workload as described earlier.

RTVS for Visual Studio 2015 is installed in: %ProgramFiles(x86)%\Microsoft Visual Studio 14\Common7\IDE\Extensions\Microsoft\R Tools for Visual Studio

Offline installation of Visual Studio and RTVS

Offline installation is suitable for computers that are not connected to the Internet:

  1. Go to Create an offline installation of Visual Studio 2017.

  2. If you use Visual Studio 2015, select 2015 in the selector above the table of contents.

  3. Follow the instructions for creating an offline installation in the web page.

  4. For Visual Studio 2015, download the offline RTVS installers from https://rtvs.blob.core.windows.net/download/RTVS_2017-12-18.1.zip and https://rtvs.blob.core.windows.net/download/RTVS_Remote_2017-12-12.1.zip.

  5. Install Visual Studio and RTVS from the offline installers.

See also