Skip to content

nb module

Numba-compiled functions for OHLCV.

Note

vectorbt treats matrices as first-class citizens and expects input arrays to be 2-dim, unless function has suffix _1d or is meant to be input to another function. Data is processed along index (axis 0).


mirror_ohlc_1d_nb function

mirror_ohlc_1d_nb(
    n_rows,
    open=None,
    high=None,
    low=None,
    close=None,
    start_value=nan,
    ref_feature=-1
)

Mirror OHLC.


mirror_ohlc_nb function

mirror_ohlc_nb(
    target_shape,
    open=None,
    high=None,
    low=None,
    close=None,
    start_value=nan,
    ref_feature=-1
)

2-dim version of mirror_ohlc_1d_nb.


ohlc_every_1d_nb function

ohlc_every_1d_nb(
    price,
    n
)

Aggregate every n price points into an OHLC point.