开发者

Getting all file names at a given folder name

开发者 https://www.devze.com 2023-02-28 20:41 出处:网络
How can I开发者_如何学Python get the names of files in a given folder name at Matlab?You should use the dir function. Like so:

How can I开发者_如何学Python get the names of files in a given folder name at Matlab?


You should use the dir function. Like so:

allFiles = dir( 'c:\my\folder' );
allNames = { allFiles.name };


If you're on linux you can call the find command and process the output. find allows for much more advanced features than just using dir, and can be called using system('find path').

0

精彩评论

暂无评论...
验证码 换一张
取 消