-
Notifications
You must be signed in to change notification settings - Fork 1
Emphasizing Text
Use the following conventions to emphasize keywords, concepts, code snippets, and other words or phrases that need to stand out or be emphasized.
- Application names
- Keywords
- R Code
- R Package Names
- Clickable Operations in Applications
- File Paths
- File and Folder Names
Capitalize the names of applications.
- Do this: Microsoft Word, RStudio.
- Do not do this: microsoft word, rstudio.
Hyperlink a keyword or phrase if it is a keyword or phrase that we would want to define in the glossary.
- Do this: Console
- Do not do this: Console, Console
Bold a keyword or phrase that we want to call attention to, but it is not necessarily a keyword or phrase that we want to define in the glossary.
At times, we will also Italicize keywords or phrases that we want to call attention to, but are not necessarily keywords or phrases that we want to define in the glossary. In general, we will follow standard English grammar rules for using the italics typeface (pay special attention to bullet 14). Further, “avoid using italics with other stylized typefaces, such as bold and underline. Since all three are designed to make words stand out, only one at a time is necessary.” (Ellis, 2022)
- Do this: We do not want to coerce participants into signing the consent form.
- Do not do this: We do NOT want to coerce participants into signing the consent form.
Snippets of programming code should be surrounded by backticks. This matches the style convention used by many popular programming websites like GitHub and Stack Overflow.
End function names with parentheses when writing then out. This is to emphasize that they are functions.
When writing about functions in the narrative part of the text (not in actual code chunks) that are not part of base R, prepend the package name with the double colon syntax. This
-
Do this:
dplyr::select()
,min()
. - Do not do this: dplyr::select(), dplyr::select(), dplyr::select(), “dplyr::select()”, min()
R package names should be surround by backticks when they are mentioned in the text. The exception is base R.
-
Do this:
dplyr
, base R. -
Do not do this: dplyr, dplyr,
base R
.
In some of the applications we use, clickable steps or operations serve
the same function as programming code. For example, in Microsoft word,
we don’t type “bold(‘Do this’)”. Instead, we highlight the phrase “Do
this” with our mouse and then click the B
button in the toolbar. Then,
Microsoft Word takes care of the programming behind the scenes for us.
Therefore, clickable operations that need to be performed in an
application should be written in the same style used to write code.
If a clickable object isn’t explicitly named, see if it has a tooltip. If it does, consider using the tooltip as its name.
-
Do this: Click the
Find/Replace
button in RStudio. - Do not do this: Click the Find/Replace button in RStudio.
All file paths should be surround by backticks when they are mentioned in the text.
-
Do this:
/Users/bradcannell/Desktop/NTRHD/my_study_data.csv
. - Do not do this: “/Users/bradcannell/Desktop/NTRHD/my_study_data.csv”.
All file paths should be surround by backticks when they are mentioned in the text.
-
Do this:
my_study_data.csv
. - Do not do this: “my_study_data.csv”.
Test Quarto Book • Contributor Guide • Wiki Home • Author Website