Mean of Multiple Matrixes
3 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
goyanks1989
am 12 Dez. 2016
Beantwortet: Roger Stafford
am 12 Dez. 2016
I have 9 matrixes all the same size (90x144), say they're called z1,z2,z3...z9
How do I take the mean of all 9 matrixes
so that the result is 1 matrix with the averages at each of the 90x144 data points?
When I try
mean(z1+z2+z3...z9)
I get a 1x144 matrix
and when I try
mean(z1,z2,z3..z9),
I get an error message
Error using mean>parseInputs (line 187)
Trailing string input must be one of 'double', 'native', 'default' or one of 'omitnan', 'includenan'.
Error in mean (line 66)
[flag, omitnan] = parseInputs(flag, flag2, isFlag2Set);
Thank you for your help
0 Kommentare
Akzeptierte Antwort
Roger Stafford
am 12 Dez. 2016
m = (z1+z2+z3+z4+z5+z6+z7+z8+z9)/9; % The mean of each element
0 Kommentare
Weitere Antworten (0)
Siehe auch
Kategorien
Mehr zu Creating and Concatenating Matrices finden Sie in Help Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!