ndwmean
ndwmean(array,weights,directions) calculates the n-dimensional weighted mean of an array. The size of the weighting array and the optional input "directions" determine the dimensions in which the weighted mean is applied (see examples). Supports NaN values.
Examples: x = rand(3,3,3,2)
ndwmean(x,rand(1,2)) % 4th dimension
ndwmean(x,rand(3,2),[2 4]) % 2nd and 4th dimensions
ndwmean(x,rand(1,3,1,2)) % 2nd and 4th dimensions
ndwmean(x,rand(1,3)) % 3rd dimension
ndwmean(x,rand(3,3)) % 2nd and 3rd dimensions
Zitieren als
Russell (2024). ndwmean (https://www.mathworks.com/matlabcentral/fileexchange/45229-ndwmean), MATLAB Central File Exchange. Abgerufen .
Kompatibilität der MATLAB-Version
Plattform-Kompatibilität
Windows macOS LinuxKategorien
- MATLAB > Language Fundamentals > Data Types > Time Series >
- MATLAB > Data Import and Analysis > Descriptive Statistics >
Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Live Editor erkunden
Erstellen Sie Skripte mit Code, Ausgabe und formatiertem Text in einem einzigen ausführbaren Dokument.
Version | Veröffentlicht | Versionshinweise | |
---|---|---|---|
1.1.0.0 | Added support for arrays with NaN values. |
||
1.0.0.0 |