How do I access a specific directory so I can then retrieve images in that directory with a specific file extension?
1 Ansicht (letzte 30 Tage)
Ältere Kommentare anzeigen
How do I access a specific directory so I can then retrieve images in that directory with a specific file extension?
0 Kommentare
Antworten (1)
Stephen23
am 9 Sep. 2019
Bearbeitet: Stephen23
am 9 Sep. 2019
D = 'relative or absolute path to the specific directory';
S = dir(fullfile(D,'*.png'));
C = {S.name} % output cell array
1 Kommentar
Walter Roberson
am 10 Sep. 2019
C = fullfile(D, {S.name}); % output cell array
to get the fully-qualified names.
Siehe auch
Kategorien
Mehr zu File Operations finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!