Cumulative Mean
                    Version 1.1.0.0 (1.65 KB) by  
                  Leandro Barajas
                
                
                  Calculates cumulative row/column mean of vectors, matrices and N-Dim arrays
                
                  
              Similar to CUMSUM but in this case each column is divided by an unity increasing weight. 
For vectors it is equivalent to:
cumsum(x)./((1:length(x))')
The CUMMEAN(x,DIM) can be taken in any non-singleton dimension (DIM).
This function is useful to compare performance of an estimator with respect to the sample mean of a set of measurements.
Cite As
Leandro Barajas (2025). Cumulative Mean (https://uk.mathworks.com/matlabcentral/fileexchange/1673-cumulative-mean), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
              Created with
              R11.1
            
            
              Compatible with any release
            
          Platform Compatibility
Windows macOS LinuxCategories
      Find more on Statistics and Machine Learning Toolbox in Help Center and MATLAB Answers
    
  Tags
Acknowledgements
Inspired: Iterative Reweighted Least Squares
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
