Export many data into the same excel file.
Show older comments
Hello Community,
I have about a thousand audio files in this directory and I want to export them to the same excel, without overwriting the previous one.

I have this code, is anyone able to improve it? Or another solution? Thank you in advance!
samp_rate = 44000;
m = 1;
cd 'some folder'
Extracted_files = dir;
nExtracted_files = length(Extracted_files);
filename = 'reference.xlsx';
for i = 1 : nExtracted_files
[data,samp_rate] = audioread(Extracted_files(i).name);
A(m) = data;
save([Extracted_files(i).name)
m = m + 1;
end
Accepted Answer
More Answers (0)
Categories
Find more on Spreadsheets in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!