Skip to content

Commit

Permalink
docs: update the docstring.
Browse files Browse the repository at this point in the history
  • Loading branch information
nkaz001 committed Sep 3, 2024
1 parent 4fdaad0 commit 21393bb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions py-hftbacktest/hftbacktest/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ def intp_order_latency(self, data: str | NDArray | List[str], latency_offset: in
Args:
data: A list of file paths for the historical order latency data in `npz`, or a NumPy array of the
historical order latency data.
latency_offset: the latency offset to adjust the order entry and response latency by the
specified amount. This is particularly useful in cross-exchange
backtesting, where the feed data is collected from a different site than
the one where the strategy is intended to run.
"""
if isinstance(data, str):
super().intp_order_latency([data], latency_offset)
Expand Down
4 changes: 4 additions & 0 deletions py-hftbacktest/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,10 @@ impl BacktestAsset {
///
/// Args:
/// data: a list of file paths for the historical order latency data in `npz`.
/// latency_offset: the latency offset to adjust the order entry and response latency by the
/// specified amount. This is particularly useful in cross-exchange
/// backtesting, where the feed data is collected from a different site than
/// the one where the strategy is intended to run.
pub fn intp_order_latency(
mut slf: PyRefMut<Self>,
data: Vec<String>,
Expand Down

0 comments on commit 21393bb

Please sign in to comment.