For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
all-in for buy
-
I ran backtest, and wanted to all-in for one stock. But it needed to set price and size, so I wondered if it could offer all-in mode when I used buy().
-
@jialeen You can use
order_target_percent(data, target=1)
to have BT use 100% of the portfolio value for the size of the order.