文件夹树文件列表
This functions goal is to return a cell array of names of files located under user defined folders. The input should be a cell array of parent directories. The function also supports input of a single directory name string. Absolute file path is used, replacing the relative path.
用户可以通过启用“ flaggui”输入来选择使用OS Explorer-的文件或目录。
我提出了一些与MATLAB文件交换的多个类似功能的未兴趣(没有犯罪,对作者及其工作,没有犯罪):
-//www.tianjin-qmedu.com/matlabcentral/fileexchange/index?term=tag%3A%22directories%22&sort=downloads_desc
-//www.tianjin-qmedu.com/matlabcentral/fileexchange/index?term=tag%3A%22files%22&sort=downloads_desc
-//www.tianjin-qmedu.com/matlabcentral/fileexchange/index?term=tag%3A%22dir%22&sort=downloads_desc
在我的第一个编程课程中,我被教导说使用递归的代码是不良的代码。递归代码很难理解,开发和维护。
Changing folders or Matlab path during run time is also a bad thing- it takes more time and can cause unwanted effects in Matlab environment.
Therefore I've written my implementation, witch, I believe, has some advantages over methods proposed earlier:
- It is not recursive but iterative.
- It does not changes the current folder (not using cd command).
- 它使用“ LS”函数,该功能应该比“ DIR”函数更快。
- According to some measurements I've made it runs faster the the alternatives.
- I also believe is is clearly written, so it should be easy to understand and maintain.
- It supports wildCards.
Cite As
Nikolay S. (2022).文件夹树文件列表(//www.tianjin-qmedu.com/matlabcentral/fileexchange/41170-folders-tree-files-list), MATLAB Central File Exchange. Retrieved.
MATLAB Release Compatibility
Platform Compatibility
视窗 macOS LinuxCategories
Tags
Acknowledgements
Inspired by:folders sub-folders
Inspired:List of files from directories/files list or browser,Files to folders based on properties,apply2VideoFrames
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
开始狩猎!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.