Add mean and mean's unit test.

This commit is contained in:
Krad
2023-04-24 15:24:23 +08:00
parent 2855d5c9a0
commit a895785319
3 changed files with 219 additions and 18 deletions

View File

@@ -51,6 +51,15 @@ namespace Aurora {
*/
Matrix sum(const Matrix& aMatrix,FunctionDirection direction = Column);
/**
* 求矩阵平均值,可按行、列、单元, 目前不支持三维,不支持复数
* @param aMatrix 矩阵
* @param direction 方向Column, Row, All
* @param aIncludeNan 是否包含nan
* @return
*/
Matrix mean(const Matrix& aMatrix,FunctionDirection direction = Column, bool aIncludeNan = true);
};