Without using the built in function "mean" (Matlab)
10 views (last 30 days)
Show older comments
How would I be able to calculate the mean of row i of a matrix "A" without using the built in function "mean"?
0 Comments
Answers (1)
Image Analyst
on 3 Nov 2017
Just loop over columns
theSum = 0;
for col = 1 : columns
theSum = theSum + m(i, col);
end
theMean = theSum / columns;
That's really super basic programming.
0 Comments
See Also
Categories
Find more on Loops and Conditional Statements 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!