Skip to content

Instantly share code, notes, and snippets.

@Canx
Created July 1, 2024 06:36
Show Gist options
  • Save Canx/a21bc0b5a1f49886918062689283d396 to your computer and use it in GitHub Desktop.
Save Canx/a21bc0b5a1f49886918062689283d396 to your computer and use it in GitHub Desktop.
backtest_date_fix
lumibot_original:
portfolio_value cash return
datetime
2023-03-03 09:30:00-05:00 100000.000000 100000.000000 NaN
2023-03-04 09:30:00-05:00 100000.000000 60029.000854 0.000000 <- these stats are from friday!!!
2023-03-06 09:30:00-05:00 100729.000854 100729.000854 0.007290 <- these stats are from weekend!
2023-03-07 09:30:00-05:00 100729.000854 100729.000854 0.000000 <- monday (6)
2023-03-08 09:30:00-05:00 100923.100464 160681.602661 0.001927 <- tuesday (7)
2023-03-09 09:30:00-05:00 100720.604126 160681.602661 -0.002006 <- wednesday (8)
lumibot polygon_day_fix:
portfolio_value cash return
datetime
2023-03-03 09:30:00-05:00 100000.000000 100000.000000 NaN
2023-03-06 09:30:00-05:00 100729.000854 100729.000854 0.007290 <- this stats are from friday (3) + weekend (4 and 5)!!!
2023-03-07 09:30:00-05:00 100018.600647 160681.602661 -0.007053 <- monday (6)
2023-03-08 09:30:00-05:00 100923.100464 160681.602661 0.009043 <- tuesday (7)
2023-03-09 09:30:00-05:00 100720.604126 160681.602661 -0.002006 <- wednesday (8)
strategy should end on 2023-03-10!! We lack another stats day!
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment