Organize yourself in RStudio

Silvie Cinková

2025-07-18

Jupyter hub at our department’s server

  • Work in your web browser, URL below.

  • Use your individual user name and password.

Figure 1: Login to Jupyterlab

Select RStudio

Figure 2: Select RStudio

Files in RStudio

Quarto Editor Options: Visual

  • many formatting options as buttons
  • document displays as a rich text, even with images inserted.

Figure 3: Quarto with the visual editor

Quarto Editor Options: Source

  • Displays strictly plain text

  • You must format everything manually.

Figure 4: Quarto editor in the source mode

YAML header

  • File YAML_header_multiformat

  • Copy-paste it into your new file to get the same formatting you see here.

  • Keep files atrium.css and atrium.tex in the same folder!!!

---
title: "Organize yourself in RStudio"
echo: true
format:
  revealjs:
    notes: true
    css: atrium.css
  pdf:
    include-in-header: atrium.tex
  html:
    css: atrium.css
---

CSS file

  • Format template for HTML pages, not R-specific.

  • Main purpose of atrium.css: larger font in code snippets

  • No atrium.css/.tex in YAML header ⟾ Quarto default

Understand note taking with these teaching materials

  • Render your source .qmd files to PDF, HTML, MS Word

  • https://quarto.org/docs/presentations/revealjs/

Figure 5: The Render button produces the document in the format you have specified in the YAML header as format.

Figure 6: When your YAML header lists multiple output formats, you have to choose which you want to render.

Resume broken connection

Figure 7: You can see this after login or being idle. Just launch the server.

Figure 8: When connection gets interrupted, you will see this. Just refresh and relaunch the server.

Control RStudio’s behavior

Figure 9: Saving, Encoding, Working directory, Line wrapping...

Check autosaving options

Figure 10: Some reasonable options for autosaving.

Control character encoding

Figure 11: UTF-8 fits most use cases.

Soft-wrap code

You will be able to see the entire line even if you narrow your browser window.

Figure 12: Control code softwrapping

Control text in .qmd/.Rmd documents

  • Soft-wrap text lines.

  • Display inserted figures in the editor (before rendering).

Figure 13: For .qmd/.Rmd documents, you have to adjust some options in a separate menu.