MCPcopy Create free account
hub / github.com/Open-Quant/openquant / build_dollar_bars

Function build_dollar_bars

python/openquant/bars.py:113–120  ·  view source on GitHub ↗
(
    df: pl.DataFrame,
    *,
    dollar_value_per_bar: float = 5_000_000.0,
)

Source from the content-addressed store, hash-verified

111
112
113def build_dollar_bars(
114 df: pl.DataFrame,
115 *,
116 dollar_value_per_bar: float = 5_000_000.0,
117) -> pl.DataFrame:
118 if dollar_value_per_bar <= 0:
119 raise ValueError("dollar_value_per_bar must be > 0")
120 return _build_by_symbol(df, _core.bars.build_dollar_bars, dollar_value_per_bar)
121
122
123def _lag1_autocorr(values: list[float]) -> float:

Callers

nothing calls this directly

Calls 1

_build_by_symbolFunction · 0.85

Tested by

no test coverage detected