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" |
list.dirs()[- 1] # Return folder names # [1] "my_dir 1" "my_dir 2" "my_dir 3" "my_dir 4" "my_dir 5"