cvxportfolio icon indicating copy to clipboard operation
cvxportfolio copied to clipboard

questions / thoughts on examples folder

Open quant5 opened this issue 1 year ago • 2 comments

I made a PR with a small refactor to two of the examples. https://github.com/cvxgrp/cvxportfolio/pull/87

I have some questions / thoughts:

  • for multiperiod_tcost.py
    • why is there a hard-coded zero-out of the portfolio on 4/20/23? Should the backtester have an end_time of 4/20/23 then?
    • if you set an initial h, initial_value becomes unnecessary / overridden, it may be worth noting this in the docs
    • drawdowns are positive numbers - it's more conventional to plot them as negative (e.g., underwater). I'd actually suggest flipping the sign of the drawdowns series when it's calculated.
  • hello_world.py - I didn't refactor this as it seems really expensive for a "hello world" - making 500 yfinance calls / filling one's hard drive with data. Suggest paring down to perhaps the example in the readme?

quant5 avatar May 25 '23 14:05 quant5