Introducing RStudio and R Markdown

Gettin’ giffy wit it.

Shannon Pileggi

Table of Contents


RStudio has some wonderful features! Here are some tips and tricks for new learneRs to get started with regards to customizing your interface, getting started with R Markdown, and a bit of troubleshooting.


Gif’s were captured in May 2019, likely with RStudio version 1.2.1335-1. Keyboard shortcuts are for Windows users, Mac users may differ. For Windows users, I also recommend changing your default settings to show file extensions.

And if you are not familiar with it, please allow me introduce you to Will Smith’s 1998 hit “Gettin’ Jiggy Wit It.” 🎵Na na na na na na na nana 🎵

Customizing the interface

Adjusting panels

Re-arrange panels

Tools -> Global Options -> Panel Layout

Recover lost panels

Font size/resolution

View -> Zoom in / Zoom out / Actual size


Tools -> Global Options -> Appearance

Margin column

Tools -> Global Options -> Code -> Display -> Show margin -> Margin column 80

Consider placing a margin column at 80 characters as a reminder for code formatting. Keeping code within 80 characters can make it easier to read when switching displays or sharing code.

R Markdown

Opening a new R Markdown

File -> New file -> R Markdown    or    -> R Markdown

Knitting an R Markdown

Preview an R Markdown

Personalizing R Markdown

Inserting/splitting code chunks

   or    Ctrl + Alt + I

Chunk anatomy

Chunk names

Chunk names allow you to quickly navigate code, automatically name figures, and troubleshoot errors. Chunk names must be unique! If no name is provided, a default numbered chunk name will be assigned.

Chunk execution

   or    Ctrl + Enter

Chunk options

R Markdown Troubleshooting

YAML error

Chunk error

Chunk error for duplicate chunk name

Layout error

Let your markdown breathe! If something doesn’t look right, try adding white space.

R code error

The end


Thumbnail artwork adapted from @allison_horst.

The phrase IDE was removed from the title and body of this post on Sep. 8, 2020 per @TrashBirdEcol’s suggestion.


Text and figures are licensed under Creative Commons Attribution CC BY 4.0. The figures that have been reused from other sources don't fall under this license and can be recognized by a note in their caption: "Figure from ...".


For attribution, please cite this work as

Pileggi (2020, Sept. 7). PIPING HOT DATA: Introducing RStudio and R Markdown. Retrieved from

BibTeX citation

  author = {Pileggi, Shannon},
  title = {PIPING HOT DATA: Introducing RStudio and R Markdown},
  url = {},
  year = {2020}