How to use for loop to calculate 15 no of sample data
Show older comments
Dear everyone..
Can somebody guide me how to write matlab code to calculate mean of several no of sample. In this case I have to calculate mean and variance of 15 no of sample under file name four(1:15) where each sample have 1000 no of data.
the example of calculation is like below:
x=mean(four(:,1);
average= mean(four(:,1)+(mean(four(:,2))......+(mean(four(:,15))
instead of one by one claculation how can i use for loop iteration command so that it can be calculated automatically. Thank you.
Answers (0)
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!