I would like to print sime summary stats at the end of a backtest. Options:
(i) Print each time in handle-data? No. Not possible due to logging limits.
(ii) Is the last period available programmatically? No. Quantopian, please add context.portfolio.end_date
(iii) Call a function after handle_data completes? No.Quantopian, please add def deinitialize(context)
(iv) Define the length of the backtest in periods? Yes. Run a 5 year backtest for 1260 days. Messy.
Any better ideas, please?
P.