how to take average of velocity matrix
3 views (last 30 days)
Show older comments
I have 200 result matrix which contains matrixes of individual variables. one of the variable is velocity v of 98x124. i need something which does the mean of velocity from each of 200 matrixes into a 1x124 matrix(like a loop or something) and finally does the mean of all these individual mean velocity matrix. So at the end i will just have one mean velocity matrix of 1x124.
2 Comments
Image Analyst
on 26 Nov 2012
What do you mean? How can your matrix contain other "matrixes of individual variables" with each element ("variable") in those matrixes being a 98 by 124 matrix in itself? Do you have 3 levels deep of matrices????
And what is a "200 result matrix"? Is that one matrix, or 200 separate matrices?
Answers (1)
Matt J
on 26 Nov 2012
Edited: Matt J
on 26 Nov 2012
Rewrite/rerun the code that created the 200 separate matrices so that instead you have one array that is 98x124x200. Then do
mean(mean(A,1),3)
2 Comments
Matt J
on 26 Nov 2012
Well, put them in that form in some other way, then. You obviously have a way of loading them into MATLAB, so load them one by one and stack them into 98x124x200 array.
See Also
Categories
Find more on Mechanical Engineering 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!