knitr::opts_chunk$set(
  collapse = TRUE,
  comment = "#>"
)

People are saying that if you are repeating a code more than twice, then make a function for it. The idea of dplyrshortcut is that if you are using a function more than twice, then use a keyboard shortcut.

Installation

You can install the development version of dplyrshortcut with the devtools package.

# install.packages("devtools")
devtools::install_github("damien-dupre/dplyrshortcut")

Use

dplyrshortcut add functions in RStudio IDE's Addins section.

knitr::include_graphics("img/img_01.png")

Then, in order to add the shortcut to your keyboard, use the Rstudio IDE: Tools>Modify Keyboard Shortcuts... and associate the keyboard shortcut you prefer, such as:

and modify Insert Pipe Operator with Ctrl+Shift+P.

knitr::include_graphics("img/img_02.png")


damien-dupre/dplyrshortcut documentation built on May 7, 2019, 3:09 p.m.