Replies: 1 comment
-
Would something like this work as a starting point ? Note that I didn't include the position manager part because that will depend on what you want to do with the information you collected.
What I'm actually doing in a pairs trading strategy where I need to keep a window of the last X closing values for a couple pairs is to use a Pandas dataframe like this:
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
From my understanding, the current dispatcher (both backtest and live) operates by sending individual ticks for each coin/ticker, with strategy/backtest processing these individually throughout (this is what's illustrated in the examples).
What would be the best approach for a setup where the position manager (or strategy?) waits to collect ticks for all tickers in scope, before making a decision. This would be required for e.g. holistic risk evaluation of all current and new positions, or prioritizing between buy/sell signals.
Is this supported in the current dispatcher setup, or do you need to integrate custom code in the position manager / strategy? What would the best of doing so?
For context, I've tried experimenting with position manager collecting signals and waiting with async until all expected ticks are collected, and then executing the holistic evaluation. However, this has issues especially in the backtest dispatcher, where signals are sent frequently via the async and not always in "expected" / chronological order.
Any ideas welcome!
Beta Was this translation helpful? Give feedback.
All reactions