-
|
I was wondering, if backtesting a strategy acting on the order book is possible with vectorbt? If no, what would be needed in order to extend the current framework to account for this need? Happy for any inputs. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
|
If your order book data can be packed into one or more NumPy arrays and you can write your strategy as an iterative process from point A to point B in time, then why not: create a callback for |
Beta Was this translation helpful? Give feedback.
If your order book data can be packed into one or more NumPy arrays and you can write your strategy as an iterative process from point A to point B in time, then why not: create a callback for
Portfolio.from_order_functhat at each timestamp reads the data and instructs vectorbt to order something. The vectorbt's approach is not that different from that of traditional backtesters.