How do I access a specific directory so I can then retrieve images in that directory with a specific file extension?
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
How do I access a specific directory so I can then retrieve images in that directory with a specific file extension?
0 comentarios
Respuestas (1)
Stephen23
el 9 de Sept. de 2019
Editada: Stephen23
el 9 de Sept. de 2019
D = 'relative or absolute path to the specific directory';
S = dir(fullfile(D,'*.png'));
C = {S.name} % output cell array
1 comentario
Walter Roberson
el 10 de Sept. de 2019
C = fullfile(D, {S.name}); % output cell array
to get the fully-qualified names.
Ver también
Categorías
Más información sobre File Operations en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!