MATLAB: Dir(cd)

dir

What does dir(cd) stand for?
files = dir(cd);

Best Answer

dir is a function that takes a look in a determined folder (and subfolder if you command).
cd without arguments is your actual location
dir(cd) would bring you all the files in your actual location.
files = dir(cd);
Will return a struct with name of the file, folder,a boolean value about if it is a folder or not, and its modification date.
Hope it helps!
Related Question