Create List of Directories & Folders Using R (Example Code)

This tutorial illustrates how to create a list of folders and subdirectories in the R programming language.

Example: Create List of Directories Using list.dirs() Function

list.dirs()[- 1] # Return folder names
# [1] "my_dir 1" "my_dir 2" "my_dir 3" "my_dir 4" "my_dir 5"

Leave a Reply

Your email address will not be published.

Fill out this field
Fill out this field
Please enter a valid email address.
You need to agree with the terms to proceed

Menu
Top