rdir.m

Function returns all subfiles, subdirectories, and size of a directory

You are now following this Submission

This function takes in an absolute folder directory and returns the absolute path of all subfiles, subfolders, and the size of the directory.
This function helped me create an automatic backup script on my computer.

Cite As

Corey (2026). rdir.m (https://ch.mathworks.com/matlabcentral/fileexchange/47125-rdir-m), MATLAB Central File Exchange. Retrieved .

Acknowledgements

Inspired: genToolboxHelp

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.1.0.0

No longer requires the last character of the absolute directory be '\'. Allows you to call rdir(cd) instead of rdir([cd '\']) for increased ease of use.

1.0.0.0