Finding the average of multiple Matrices on multiple files

I am trying to find the average, max and min of matrices piece by piece, not as a whole matrices. I have tried to use a for loop but I think I am too beginner to make it work. I have 7 files, each with their own matrices that I would like to bring in and average them. Any ideas?
Thank you!

Answers (1)

An example:
folder='E:\Matlab';
filetype='*.xls'; % or xlsx , specify the correct format of your files
f=fullfile(folder,filetype);
d=dir(f);
for k=1:numel(d);
data{k}=xlsread(fullfile(folder,d(k).name));
Average{k}=mean{k};
end
Read processing sequence of files for better understanding.

Categories

Find more on Loops and Conditional Statements in Help Center and File Exchange

Asked:

on 18 Oct 2018

Edited:

on 19 Oct 2018

Community Treasure Hunt

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

Start Hunting!