Skip to content

R Extension for Visual Studio Code (execution, snippet, lint, R documantation, R Markdown)

License

Notifications You must be signed in to change notification settings

masterhands/vscode-R

 
 

Repository files navigation

R support for Visual Studio Code

Requires R.

Usage

  • For Windows, set config r.rterm.windows to your R.exe Path like "C:\\Program Files\\R\\R-3.3.4\\bin\\x64\\R.exe";
  • For Radian console, enable config r.bracketedPaste
  • Open your folder that has R source file (Can't work if you open only file)
  • Use F1 key and R: command or Ctrl+Enter(Mac: ⌘+Enter)

Features

  • Run Source(Ctrl+Shift+S or Push iconicon) and Run Selected Line (Ctrl+Enter)
  • Run nrow, length, head, thead, names functions (Ctrl + 1, 2, 3, 4, 5)
    • If you are using Mac Ctrl to

use Run .R

  • R Integrated Terminal

Create R terminal

  • Run code in terminal containing existing R session, for example over SSH (Run Selection/Line in Active Terminal)
  • Run all commands in terminal containing existing R session (enable config r.alwaysUseActiveTerminal)

R over SSH

  • Extended Syntax(R, R Markdown, R Documentation)

Syntax

  • Create .gitignore based R.gitignore

  • Data frame viewer and Environment viewer(Preview Data frame or Preview Environment)

Image

  • Snippets

  • Package development short cut (Load All, Test Package, Install Package, Build Package and Document)

Requirements

Extension Settings

This extension contributes the following settings:

  • r.rterm.windows: set to R.exe path for Windows

  • r.rterm.mac: set to R term's path for Mac OS X

  • r.rterm.linux: set to R term's path for Linux

  • r.rpath.lsp: set to R.exe path for Language Server Protocol

  • r.rterm.option: R command line options (i.e: --vanilla)

  • r.source.encoding: An optional encoding to pass to R when executing the file

  • r.source.focus: Keeping focus when running (editor or terminal)

  • r.alwaysUseActiveTerminal: Use active terminal for all commands, rather than creating a new R terminal

  • r.bracketedPaste: For consoles supporting bracketed paste mode (such as Radian)

  • Language server(developing here)

TODO

  • Output Plot
  • Debug

CONTRIBUTING

This extension based on

Collaborators

I hope you will join us.

FAQ

  • Q: I can't use command and message is xxx no command found.
  • A: Please open your folder that has R source file

The R logo is © 2016 The R Foundation

About

R Extension for Visual Studio Code (execution, snippet, lint, R documantation, R Markdown)

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 96.4%
  • JavaScript 2.3%
  • R 1.3%