fast_cov( X )
Version 1.0.0.0 (587 Bytes) by
Joseph Betthauser
fast_cov(X): Covariance calculation 15-35% faster than MATLAB built-in cov() for high-dimensional X
fast_cov(): Covariance calculation 15-35% faster than MATLAB built-in cov() for high-dimensional X
Input X : M x N ( # features x # samples)
Output Xcov : M x M covariance matrix
NOTE: Easy to confirm that output of fast_cov(X) == cov(X')
Cite As
Joseph Betthauser (2026). fast_cov( X ) (https://www.mathworks.com/matlabcentral/fileexchange/65070-fast_cov-x), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Created with
R2017b
Compatible with any release
Platform Compatibility
Windows macOS LinuxCategories
Find more on Statistics and Machine Learning Toolbox in Help Center and MATLAB Answers
Tags
Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
| Version | Published | Release Notes | |
|---|---|---|---|
| 1.0.0.0 | Specified that the speed boost is achieved particularly for high-dimensional data. For small data matrices, cov() is faster or equivalent. |
