How to loop multiple text files with different filenames ?
Mostrar comentarios más antiguos
Hello,
I have multiple text files with different filenames like x001.txt, where x is varying from a-d. I have imported all the files. How to i loop them for reading the data from each of the text file. Thanks.
4 comentarios
madhan ravi
el 8 de Mzo. de 2019
doc sprintf
Prajwal Kadlaplamutt Ravindra Kumar
el 8 de Mzo. de 2019
Mansa Murthy
el 8 de Mzo. de 2019
Hi..how to save extracted features of 100 images in one .mat file?
i want to save all the values (homogenity,contrast,energy) of 100 images in one .mat file?
Respuestas (1)
KSSV
el 8 de Mzo. de 2019
files = dir('*.txt') ;
N = length(files) ;
for i = 1:N
thisfile = files(i).txt ;
% Do what you want
end
Categorías
Más información sobre Loops and Conditional Statements en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!