B Conventions

This book will use the following conventions:

  • Generic code: list(number = 1, letter = "A")
  • Highlighted code: dplyr::slice_max()
  • File paths: data/sales.csv
  • R Packages: tidyverse
  • Functions: paste()
  • Strings: "psyTeachR"
  • Numbers: 100, 3.14
  • Logical values: TRUE, FALSE
  • Glossary items: ordinal
  • Citations: Wickham (2023)
  • Internal links: ChapterĀ 1
  • External links: R for Data Science
  • Menu/interface options: New File...

B.1 Webexercises

See webexercises for more details about how to use this in your materials.

  • Type an integer:
  • I am going to learn a lot:
  • What is a p-value?

You found some hidden text!

print("You found some hidden code!")
## [1] "You found some hidden code!"

B.2 Alert boxes

Informational asides.

Notes to warn you about something.

Notes about things that could cause serious errors.

Try it yourself.

B.3 Code Chunks

# code chunks
paste("Applied", "Data", "Skills", 1, sep = " ")
## [1] "Applied Data Skills 1"
```{r setup, message = FALSE}
# code chunks with visible r headers
library(tidyverse)
```

B.4 Glossary

term definition
<a href='https://psyteachr.github.io/glossary/o#ordinal' target='_blank'>ordinal</a> Discrete variables that have an inherent order, such as level of education or dislike/like.