|
tatami_stats
Matrix statistics for tatami
|
Functions for counting zeros on each dimension. More...
Classes | |
| struct | Options |
| Zero-counting options. More... | |
Functions | |
| template<typename Value_ , typename Index_ , typename Output_ > | |
| void | apply (bool row, const tatami::Matrix< Value_, Index_ > &mat, Output_ *output, const Options &zopt) |
| template<typename Output_ = int, typename Value_ , typename Index_ > | |
| std::vector< Output_ > | by_row (const tatami::Matrix< Value_, Index_ > &mat, const Options &zopt) |
| template<typename Output_ = int, typename Value_ , typename Index_ > | |
| std::vector< Output_ > | by_row (const tatami::Matrix< Value_, Index_ > &mat) |
| template<typename Output_ = int, typename Value_ , typename Index_ > | |
| std::vector< Output_ > | by_column (const tatami::Matrix< Value_, Index_ > &mat, const Options &zopt) |
| template<typename Output_ = int, typename Value_ , typename Index_ > | |
| std::vector< Output_ > | by_column (const tatami::Matrix< Value_, Index_ > &mat) |
Functions for counting zeros on each dimension.
| void tatami_stats::counts::zero::apply | ( | bool | row, |
| const tatami::Matrix< Value_, Index_ > & | mat, | ||
| Output_ * | output, | ||
| const Options & | zopt ) |
| Value_ | Type of the matrix value, should be summable. |
| Index_ | Type of the row/column indices. |
| Output_ | Type of the output value. This should be at least large enough to hold the dimensions of p. |
| row | Whether to obtain a count for each row. | |
| mat | Instance of a tatami::Matrix. | |
| [out] | output | Pointer to an array of length equal to the number of rows. On output, this will store the number of zeros in each row. |
| zopt | Counting options. |
| std::vector< Output_ > tatami_stats::counts::zero::by_row | ( | const tatami::Matrix< Value_, Index_ > & | mat, |
| const Options & | zopt ) |
Wrapper around apply() for row-wise zero counts.
| Value_ | Type of the matrix value, should be summable. |
| Index_ | Type of the row/column indices. |
| Output_ | Type of the output value. This should be at least large enough to hold the dimensions of p. |
| mat | Instance of a tatami::Matrix. |
| zopt | Counting options. |
| std::vector< Output_ > tatami_stats::counts::zero::by_row | ( | const tatami::Matrix< Value_, Index_ > & | mat | ) |
Overload with default options.
| Output_ | Type of the output value. This should be at least large enough to hold the dimensions of p. |
| Value_ | Type of the matrix value, should be summable. |
| Index_ | Type of the row/column indices. |
| mat | Instance of a tatami::Matrix. |
| std::vector< Output_ > tatami_stats::counts::zero::by_column | ( | const tatami::Matrix< Value_, Index_ > & | mat, |
| const Options & | zopt ) |
Wrapper around apply() for column-wise zero counts.
| Output_ | Type of the output value. This should be at least large enough to hold the dimensions of p. |
| Value_ | Type of the matrix value, should be summable. |
| Index_ | Type of the row/column indices. |
| mat | Instance of a tatami::Matrix. |
| zopt | Counting options. |
| std::vector< Output_ > tatami_stats::counts::zero::by_column | ( | const tatami::Matrix< Value_, Index_ > & | mat | ) |
| Output_ | Type of the output value. This should be at least large enough to hold the dimensions of p. |
| Value_ | Type of the matrix value, should be summable. |
| Index_ | Type of the row/column indices. |
| mat | Instance of a tatami::Matrix. |