Saving and Naming Files

  1. File names should be machine readable
    • avoid spaces, symbols, and special characters. Don’t rely on case sensitivity to distinguish files.
  2. File names should be human readable
    • use file names to describe what’s in the file.
  3. File names should play well with default ordering
    • start file names with numbers so that alphabetical sorting puts them in the order they get used.

Examples of good names:

01-load-data.R
02-exploratory-analysis.R
03-model-approach-1.R
04-model-approach-2.R
fig-01.png
fig-02.png
report-2022-03-20.qmd
report-2022-04-02.qmd
report-draft-notes.txt

Jenny Bryan’s talk on ‘How to name files like a Normie’

More File Naming Conventions