MATLAB Functions | Help Desk |
dir
Directory listing
dir dirdirname
names = dir names = dir('dirname
')
dir,
by itself, lists the files in the current directory.
dir dirname
lists the files in the specified directory. Use pathnames, wildcards, and any options available in your operating system.
names = dir('dirname
') or names = dir
returns the results in an m
-by-1
structure with the fields:
cd /Matlab/Toolbox/Local; dir Contents.m matlabrc.m siteid.m userpath.m names = dir names = 4x1 struct array with fields: name date bytes isdir
!
, cd
, delete
, type
, what