pmean.m v1.1 (Sep 2009)

MEAN and STD of angles, polar, cylindrical, spherical or cartesian coordinates!
2.6K 次下载
更新时间 2009/9/21

查看许可证

This function calculates the mean and standard deviation of vectors in polar coordinates (and others), that is, from angles and magnitudes.

The usage is very simple:

For polar or cylindrical: Direction, Radius, Height
[mD,eD] = pmean(D);
[mD,mR,eD,eR] = pmean(D,R);
[mD,mR,mH,eD,eR,eH] = pmean(D,R,H);

For spherical coordinates: Azimuth, Elevation, Radius
[mA,eA] = pmean(A);
[mA,mE,eA,eE] = pmean(A,E,'s');
[mA,mE,mR,eA,eE,eR] = pmean(A,E,R,'s');

For cartesian coordinates:
[mX,eX] = pmean(X,'c');
[mX,mY,eX,eY] = pmean(X,Y,'c');
[mX,mY,mZ,eX,eY,eZ] = pmean(X,Y,Z,'c');

where "m" stands for MEAN's, and "e" for STD's.

Input angles should be in radians.

It ignores NaN's.

Enjoy it!
Any comments or bug reports will be very appreciated!

引用格式

Carlos Adrian Vargas Aguilera (2025). pmean.m v1.1 (Sep 2009) (https://ww2.mathworks.cn/matlabcentral/fileexchange/19643-pmean-m-v1-1-sep-2009), MATLAB Central File Exchange. 检索时间: .

MATLAB 版本兼容性
创建方式 R2008b
兼容任何版本
平台兼容性
Windows macOS Linux
类别
Help CenterMATLAB Answers 中查找有关 Antennas, Microphones, and Sonar Transducers 的更多信息

Community Treasure Hunt

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

Start Hunting!
版本 已发布 发行说明
1.1.0.0

v1.1 Fixed IMPORTANT bug with angle STD estimation. Changed help and comments.

1.0.0.0

English correction and changes in the help.