Calculating the mean of a non-continuous data set

Hi all,
I am a total beginner with MatLab and I am trying to caclulate the means of a (223x20) array, however the majority of columns do not have a continous data set i.e only have 60 out of 223 data entries.
As a result i am seeing NaN for the majority of my means when using the basic mean(A) function.
Would really appreciate any help!

More Answers (1)

Thanks! i found
MeanX=mean(X,'omitnan');
to be useful as well.

Products

Release

R2016b

Community Treasure Hunt

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

Start Hunting!