Go to the source code of this file.
|
template<typename T > |
Matrix< T > | HadamardMulti (const Matrix< T > &lhs, const Matrix< T > &rhs) |
|
template<typename T > |
Matrix< T > | HadamardDiv (const Matrix< T > &lhs, const Matrix< T > &rhs) |
|
template<typename T > |
Matrix< T > | KroneckerMulti (const Matrix< T > &lhs, const Matrix< T > &rhs) |
|
template<typename T > |
Matrix< T > | HorizontalConcat (const Matrix< T > &lhs, const Matrix< T > &rhs) |
|
template<typename T > |
size_t | Corr (const Matrix< T > &A, const Matrix< T > &B) |
|
template<typename T > |
Matrix< T > | from_vptr (const T *value, MatrixDimension size) |
|
template<typename T > |
size_t | argmax (const Matrix< T > &mat) |
|
template<typename T > |
size_t | argmin (const Matrix< T > &mat) |
|
template<typename T > |
Matrix< T > | where (const std::function< bool(T)> &condition, const Matrix< T > &in, const Matrix< T > &valIfTrue, const Matrix< T > &valIfFalse) |
|
template<typename T > |
Matrix< size_t > | where_value (const Matrix< T > &in, T value) |
|
template<typename T > |
Matrix< size_t > | where_true (const Matrix< T > &in) |
|
template<typename T > |
Matrix< size_t > | where_false (const Matrix< T > &in) |
|
template<typename T > |
std::vector< std::pair< Matrix< T >, Matrix< T > > > | zip (const Matrix< T > &a, const Matrix< T > &b) |
|
template<typename T > |
T | max (const Matrix< T > &mat) |
|
template<typename T > |
Matrix< T > | max (const Matrix< T > &mat, int axis) |
|
template<typename T > |
T | min (const Matrix< T > &mat) |
|
template<typename T > |
Matrix< T > | min (const Matrix< T > &mat, int axis) |
|
template<typename T > |
T | elemMax (const Matrix< T > &mat, const size_t &elemIndex) |
|
template<typename T > |
T | elemMin (const Matrix< T > &mat, const size_t &elemIndex) |
|
template<typename T > |
Matrix< T > | mean (const Matrix< T > &mat, int axis=-1) |
|
template<typename T > |
T | elemMean (const Matrix< T > &mat, const size_t &elemIndex) |
|
template<typename T > |
Matrix< T > | diag_elements (const Matrix< T > &in) |
|
template<typename T > |
Matrix< T > | unique (const Matrix< T > &in, int axis=0) |
|
Matrix< double > | zeros (size_t rows, size_t columns, size_t elements=1) |
|
Matrix< double > | eye (size_t rows, size_t columns) |
|
◆ argmax()
Search index of value with maximum value Caution! This value does represent the index in a ongoing array.
- Template Parameters
-
- Parameters
-
- Returns
- Examples
- TestMatrix.cpp.
◆ argmin()
Search index of value with lowest value Caution! This value does represent the index in a ongoing array.
- Template Parameters
-
- Parameters
-
- Returns
- index of minimal value
- Examples
- TestMatrix.cpp.
◆ Corr()
Counts correlations between A
and B
- Template Parameters
-
- Parameters
-
A | matrix to compare |
B | matrix to compare with |
- Returns
- number of element wise equal elements
- Examples
- TestMatrix.cpp.
◆ diag_elements()
Returns Vector of diagonal elements from matrix.
- Template Parameters
-
- Parameters
-
- Returns
- vector of diagonal elements
◆ elemMax()
Max value from given element index in matrix
- Template Parameters
-
- Parameters
-
mat | matrix to search in |
elemIndex | index of element to compute max value of |
- Returns
- max value over all elements with given index
- Examples
- TestMatrix.cpp.
◆ elemMean()
mean operation on element with given index
- Template Parameters
-
- Parameters
-
mat | input matrix |
elemIndex | index of element to compute mean of |
- Returns
- mean of all elements
- Examples
- TestMatrix.cpp.
◆ elemMin()
Min value from given element index in matrix
- Template Parameters
-
- Parameters
-
mat | matrix to search in |
elemIndex | index of element to compute max value of |
- Returns
- min value over all elements with given index
◆ eye()
◆ from_vptr()
Converts array of elements of type T
into matrix of given size
- Template Parameters
-
- Parameters
-
value | pointer to array of elements of type T |
size | dimension of target matrix |
- Returns
- Examples
- TestMatrix.cpp.
◆ HadamardDiv()
Element wise division
- Template Parameters
-
- Parameters
-
lhs | left hand side with dimension n1, m1 |
rhs | right hand side with dimension n1, m1 |
- Returns
- product of element wise multiplication of lhs * rhs with dimension n1, m1
◆ HadamardMulti()
Helper utilities Element wise multiplication
- Template Parameters
-
- Parameters
-
lhs | left hand side with dimension n1, m1 |
rhs | right hand side with dimension n1, m1 |
- Returns
- product of element wise multiplication of lhs * rhs with dimension n1, m1
◆ HorizontalConcat()
Horizontal concatenation of 2 matrices of same Row size
- Template Parameters
-
- Parameters
-
lhs | left hand side with dimension n1, m1 |
rhs | right hand side with dimension n1, m2 |
- Returns
- concatenated matrix [lhs, rhs] of dimension n1, m1 + m2
◆ KroneckerMulti()
A form of matrix multiplication For explicit reference please consult https://en.wikipedia.org/wiki/Kronecker_product
- Template Parameters
-
- Parameters
-
lhs | left hand side with dimension n1, m1 |
rhs | right hand side with dimension n2, m2 |
- Returns
- resulting matrix with dimension n1 * n2, m1 * m2
◆ max() [1/2]
Max value of given Matrix
- Template Parameters
-
- Parameters
-
mat | matrix to search max value in |
- Returns
- max value of given matrix
◆ max() [2/2]
◆ mean()
Calculates mean over given axis
- Template Parameters
-
- Parameters
-
mat | matrix to calculate mean of |
axis | axis along which to calculate the mean (-1: no axis - over all elements, 0: row wise, 1: column wise) |
- Returns
- mean of elements inside given matrix along given axis
- Examples
- TestMatrix.cpp.
◆ min() [1/2]
Min value of given matrix
- Template Parameters
-
- Parameters
-
mat | matrix to search min value in |
- Returns
- min value of matrix
◆ min() [2/2]
◆ unique()
Returns unique values of given matrix.
- Template Parameters
-
- Parameters
-
- Returns
- matrix of unique values
- Examples
- TestMatrix.cpp.
◆ where()
Returns elements chosen from valIfTrue
or valIfFalse
depending on condition
- Template Parameters
-
- Parameters
-
condition | lambda/function to test a condition on every element of in |
in | input values |
valIfTrue | value vector with values in case in meets condition |
valIfFalse | value vector with values in case in does not meet condition |
- Returns
- Examples
- TestMatrix.cpp.
◆ where_false()
Evaluates elements of a given vector. Responds with indices of true values.
- Parameters
-
- Returns
- vector of indices where element has true value
◆ where_true()
Evaluates elements of a given vector. Responds with indices of true values.
- Parameters
-
- Returns
- vector of indices where element has true value
◆ where_value()
Evaluates elements of a given vector. Responds with indices of true values.
- Parameters
-
- Returns
- vector of indices where element has true value
◆ zeros()
◆ zip()
Converts two input matrices into a vector of row-wise pairs of a
and b
- Template Parameters
-
- Parameters
-
- Returns