|
PineForge unreleased
Deterministic PineScript v6 backtest runtime — C ABI reference
|
#include <generic_matrix.hpp>
Data Structures | |
| class | Snapshot |
Public Member Functions | |
| GenericMatrix () noexcept=default | |
| GenericMatrix (const GenericMatrix &) noexcept=default | |
| GenericMatrix & | operator= (const GenericMatrix &) noexcept=default |
| GenericMatrix (GenericMatrix &&other) noexcept | |
| GenericMatrix & | operator= (GenericMatrix &&other) noexcept |
| ~GenericMatrix ()=default | |
| T | get (int row, int col) const |
| void | set (int row, int col, T val) |
| void | fill (T val) |
| int | rows () const |
| int | columns () const |
| std::vector< T > | row (int idx) const |
| std::vector< T > | col (int idx) const |
| template<typename U = T, typename = std::enable_if_t<!std::is_same_v<U, bool>>> | |
| const std::vector< T > & | row_ref (int idx) const |
| void | add_row (int idx, const std::vector< T > &values) |
| void | add_col (int idx, const std::vector< T > &values) |
| void | remove_row (int idx) |
| void | remove_col (int idx) |
| void | swap_rows (int i, int j) |
| void | swap_columns (int i, int j) |
| GenericMatrix | copy () const |
| GenericMatrix | submatrix (int from_row, int to_row, int from_col, int to_col) const |
| GenericMatrix | transpose () const |
| GenericMatrix | concat (const GenericMatrix &other, bool horizontal) const |
| void | reshape (int new_rows, int new_cols) |
| void | reverse () |
| void | sort (int column, bool ascending=true) |
| int | elements_count () const |
| bool | is_na () const noexcept |
| Snapshot | snapshot () const |
| void | restore (const Snapshot &snapshot) |
Static Public Member Functions | |
| static GenericMatrix | new_ (int rows, int cols, T init) |
| static GenericMatrix | new_ (int rows, int cols) |
Definition at line 164 of file generic_matrix.hpp.
|
defaultnoexcept |
|
defaultnoexcept |
|
inlinenoexcept |
Definition at line 206 of file generic_matrix.hpp.
|
default |
|
defaultnoexcept |
|
inlinenoexcept |
Definition at line 208 of file generic_matrix.hpp.
|
inlinestaticnodiscard |
Definition at line 234 of file generic_matrix.hpp.
References GenericMatrix(), pineforge::detail::matrix_call_error(), and rows().
Referenced by pineforge::GenericMatrix< bool >::new_().
|
inlinestaticnodiscard |
Definition at line 244 of file generic_matrix.hpp.
References GenericMatrix(), pineforge::detail::matrix_call_error(), and rows().
|
inline |
Definition at line 256 of file generic_matrix.hpp.
References col(), columns(), pineforge::detail::matrix_call_error(), row(), and rows().
|
inline |
Definition at line 269 of file generic_matrix.hpp.
References col(), columns(), pineforge::detail::matrix_call_error(), row(), and rows().
|
inline |
Definition at line 282 of file generic_matrix.hpp.
|
inline |
Definition at line 286 of file generic_matrix.hpp.
Referenced by add_row(), pineforge::GenericMatrix< bool >::add_row(), concat(), pineforge::GenericMatrix< bool >::concat(), get(), pineforge::GenericMatrix< bool >::get(), new_(), new_(), remove_row(), pineforge::GenericMatrix< bool >::remove_row(), row(), pineforge::GenericMatrix< bool >::row(), row_ref(), set(), pineforge::GenericMatrix< bool >::set(), submatrix(), pineforge::GenericMatrix< bool >::submatrix(), swap_rows(), pineforge::GenericMatrix< bool >::swap_rows(), transpose(), and pineforge::GenericMatrix< bool >::transpose().
|
inline |
Definition at line 289 of file generic_matrix.hpp.
Referenced by add_col(), pineforge::GenericMatrix< bool >::add_col(), add_row(), col(), pineforge::GenericMatrix< bool >::col(), concat(), pineforge::GenericMatrix< bool >::concat(), get(), pineforge::GenericMatrix< bool >::get(), remove_col(), pineforge::GenericMatrix< bool >::remove_col(), set(), pineforge::GenericMatrix< bool >::set(), submatrix(), pineforge::GenericMatrix< bool >::submatrix(), swap_columns(), pineforge::GenericMatrix< bool >::swap_columns(), transpose(), and pineforge::GenericMatrix< bool >::transpose().
|
inline |
Definition at line 294 of file generic_matrix.hpp.
References pineforge::detail::matrix_call_error(), and rows().
Referenced by add_col(), get(), pineforge::GenericMatrix< bool >::get(), set(), and pineforge::GenericMatrix< bool >::set().
|
inline |
Definition at line 303 of file generic_matrix.hpp.
References columns(), and pineforge::detail::matrix_call_error().
Referenced by get(), pineforge::GenericMatrix< bool >::get(), set(), and pineforge::GenericMatrix< bool >::set().
|
inline |
Definition at line 317 of file generic_matrix.hpp.
References pineforge::detail::matrix_call_error(), and rows().
|
inline |
Definition at line 326 of file generic_matrix.hpp.
References columns(), pineforge::detail::matrix_call_error(), and rows().
|
inline |
Definition at line 340 of file generic_matrix.hpp.
References columns(), pineforge::detail::matrix_call_error(), and row().
|
inline |
Definition at line 365 of file generic_matrix.hpp.
References pineforge::detail::erase_row(), pineforge::detail::matrix_call_error(), and rows().
|
inline |
Definition at line 374 of file generic_matrix.hpp.
References columns(), pineforge::detail::erase_col(), and pineforge::detail::matrix_call_error().
|
inline |
Definition at line 383 of file generic_matrix.hpp.
References pineforge::detail::matrix_call_error(), rows(), and pineforge::detail::swap_rows_impl().
|
inline |
Definition at line 392 of file generic_matrix.hpp.
References columns(), pineforge::detail::matrix_call_error(), and pineforge::detail::swap_cols_impl().
|
inlinenodiscard |
Definition at line 401 of file generic_matrix.hpp.
References GenericMatrix().
Referenced by concat(), and pineforge::GenericMatrix< bool >::concat().
|
inlinenodiscard |
Definition at line 405 of file generic_matrix.hpp.
References columns(), pineforge::detail::copy_submatrix(), GenericMatrix(), pineforge::detail::matrix_call_error(), and rows().
|
inlinenodiscard |
Definition at line 429 of file generic_matrix.hpp.
References columns(), GenericMatrix(), rows(), and pineforge::detail::transpose_impl().
|
inlinenodiscard |
Definition at line 436 of file generic_matrix.hpp.
References columns(), pineforge::detail::concat_impl(), copy(), pineforge::detail::matrix_call_error(), and rows().
|
inline |
Definition at line 455 of file generic_matrix.hpp.
References pineforge::detail::reshape_impl().
|
inline |
Definition at line 461 of file generic_matrix.hpp.
|
inline |
Definition at line 466 of file generic_matrix.hpp.
References pineforge::detail::sort_impl().
|
inline |
Definition at line 474 of file generic_matrix.hpp.
References pineforge::detail::elements_count_impl().
|
inlinenodiscardnoexcept |
Definition at line 478 of file generic_matrix.hpp.
|
inlinenodiscard |
Definition at line 480 of file generic_matrix.hpp.
Referenced by restore().
|
inline |
Definition at line 485 of file generic_matrix.hpp.
References pineforge::detail::matrix_snapshot_error(), and snapshot().