Skip to main content

Data Management Planning: File Organization

Information on best practices and standards for data management planning.

General Information

 

 

 

Location

Staffed Hours: Fall 2017

Contact Us

Tell us how we're doing

 

Documenting File Name Conventions

Projects often develop over the course of many years, and usually involve periodic work interrupted by spans of inactivity. To ensure that naming conventions are understood months or years after they are initially conceived, include a readme.txt file or some kind of file manifest (in a plain text or other sustainable format) in your directory that explains the contents of files and the naming system developed.

File Naming Best Practices

File naming, when done in a well-organized fashion, can contribute to project documentation, workflow organization, and sharing. Moreover, certain choices in file naming are essential to accessing and sharing files across a computing systems.

 

Best Practices for Software Compatibility and File Sharing

  • Consider starting file names with a letter character (leading numerical characters are occasionally not permitted in some software environments).
  • Avoid special characters; use letters and numbers.
  • Do not make file identity dependent on capitalization; stick with lower-case characters unless implementing camel case (e.g. fileName.xml).
  • Never use spaces in filenames, as many systems do not recognize them or will give errors unless such filenames are treated specially. Use an underscore _ instead of a space.
  • Use short file names, as some systems will balk at long file paths

 

Best Practices for Human Readability, Organization, and Long-Term Usability

  • Ensure that your file system will sort numerical portions of file names as logically as possible by using a set number of digits. For example, use 1001, 1002, 1003 or 001, 002, 003 instead of 1, 2, 3.
  • When using dates in file names, use only digits and provide descending granularity to enable chronological grouping, i.e. year digits followed by month digits, then day digits. Since files are sorted by the leftmost character, this will ensure that all files from a certain year will be grouped together, and within those years, all months, days, etc.
  • Choose file names that are recognizable to humans and that make sense within the project environment by including information such as:
    • Name of creator (say, in a collaboratively built project)
    • Date
    • Version number (avoid terms like "final" or "latest," since file versions usually not final)
    • Descriptive term for object referenced by the file (a text title, a specimen name, a geographical location, a scientific instrument type)
    • Project information

 

Examples of File Naming

  1. loc_aws_150821_cartoon_1864_001.pdf

    Where:

    • loc refers to an archive name (Library of Congress)
    • aws refers to a collection name (Alfred Whital Stern Collection)
    • 150821 refers to the date scanned (8/21/2015)
    • cartoon names a format
    • 1864 gives the year of the original document
    • 001 is the first instance of this type of document in the scanned files

  2. uk_amphibia_bufo_20131220_ms_1002.tif

    Where:

    • uk refers to an geographical location of specimen collection
    • amphibia refers to a biological class
    • bufo refers to a biological genus
    • 20131220 gives the date of the specimen collection (12/20/2013)
    • ms initials of group member responsible for creating this file
    • 1002 is the second instance of this type of document in this group of image files

Documenting File Trees

Avoiding this tangled nest of files and folders is why file naming is so important, but ALSO why documenting file locations is important. You can do this easily by adding a READme file in your folders, which can tell you, link you to, and describe, all the files in a particular folder. 

The Data Management team has written some scripts to automatically generate a READme file of all the files in a folder: Mac and Windows (Windows--to CSV also).

CC

Creative Commons License
Original work in this LibGuide is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.