For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
Plotting observers
-
Hi, can i adjust which observers are plotted? Specifically I'm trying to just plot just the broker value line (equity curve), not the cash line. Thanks!
-
cerebro.addobserver(bt.observers.Value) cerebro.run(stdstats=False)
stdstats
remove the default set ofobservers
which are added to the plots. From there on the end user has to add those he/she may be interested in (like above) -
Thanks that works. Btw, is there a way for me to just plot the broker value line only, removing even the price bars?
-
@ng_joehoong Just like with any other object.
plot=False
to suppress the data.See the latest
btfd
post for an example: https://www.backtrader.com/blog/posts/2016-12-26-btfd/btfd.html -
Perfect thanks!