For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
Backtesting Using Intraday Data
-
My data is in the format below:
7/29/2019 6:00
7/29/2019 6:15
7/29/2019 6:30
7/29/2019 6:45
7/29/2019 7:00
7/29/2019 7:15
7/29/2019 7:30
7/29/2019 7:45
7/29/2019 8:00
7/29/2019 8:15i.e I get a price every 15 minutes.
This is stored in Pandas Dataframe.When I load it,
data = bt.feeds.PandasData(...., timeframe=bt.TimeFrame.Minutes, compression = 1)
Compression should be = 1 or 15?
-
Hi, it should be compresssion = 15. Note: if your data is large, you may want to consider bt.feed.PandasDataDirect that seems to be faster than PandasData. Someone has conducted a perf analysis on this forum. you should be able to find easily. Cheers