Azzera filtri
Azzera filtri

How to store multiple cell array in excel file

3 visualizzazioni (ultimi 30 giorni)
Im having an image folder with 30 images .
I am using this code:
srcFiles = dir('image folder\*.jpg');
to store all images in an array.
To read all image files in a for loop simultaneously, im using the below code :
for i = 1 : length(srcFiles)
length(srcFiles)
filename = strcat('image folder\',srcFiles(i).name);
I{i} = imread(filename);
Then some execution done and modified image is generated.
some comparative features are calculated then. like :
MyPsnr = psnrIM( MyIM,I );
MyCorr = corr2(MyIM, I) ;
Then store all the features in a cell array.
MyFeature = [ MyPsnr, MyCorr, timeMy];
The problem is :
To save the cell array in an excel file im using the code:
xlswrite('folder\name.xlsx', MyFeature);
it is storing only 1 image features.
How could i save all 30 image features in a single excel file ?

Risposta accettata

Walter Roberson
Walter Roberson il 1 Dic 2015
In the loop
MyFeature{i,1} = MyPsnr;
MyFeature{i,2} = MyCorr;
MyFeature{i,3} = timeMy;
And do not write the xls file inside the loop: write it once outside the loop using that same syntax
xlswrite('folder\name.xlsx', MyFeature);

Più risposte (0)

Categorie

Scopri di più su Images in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by