Additional Addins for RStudio
I'm a really big fan of some of the RStudio Addins. Most notable: datapasta, clipr, and snippetsaddins. There are so many other greats ones but I use these over and over. The most comprehensive list can be found at the addinslist. A cool thing with Addins is that you can assign them to Keyboard Shortcuts.
As I write code in R, some things I type repetitively. Especially as I style and commment my code. I created these Addins to turn some of those things into keyboard shortcuts. I did pretty much the same thing using RStudio snippets, but this project gave me the personal benefit of learning about Addins.
Inspiration from
insertBigBreakAddin
: Inserts the text that I use when I am coding and want to indicate a big section break.insertLittleBreakAddin
: Inserts the text that I use when I am coding and want to indicate a little section break.
Once installed, in RStudio, I navigate to Tools > Modify keyboard shortcuts, and make the following assignments
Ctrl+Alt+B
for the Big Break, andCtrl+Alt+L
for the Little Break
Not sure if these conflict with other keyboard shortcuts (as of 2018-05-03).
Inserts the following text into your code:
#### ----------------------------
Then type a title or header for that section
#### Section One -------------------------------
# Sections are separated visually with 4 comment characters and 32 dashes
# The last 4 dashes at the end of the comment are a section marker supported by
# RStudio
Inserts the following text into your code:
## ----------------
Combined with the Big Section Break code is organized like so
#### Section One -------------------------------
# Sections are separated visually with 4 comment characters and 32 dashes
## Sub-section One ----------------
# Subsection with 2 comment characters and 16 dashes
# The last 4 dashes at the end of the comment are a section marker supported by
# RStudio
devtools::install_github("emilelatour/laaddins")