Navigation

    Backtrader Community

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    1. Home
    2. saidalateral
    For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
    S
    • Profile
    • Following 0
    • Followers 0
    • Topics 1
    • Posts 1
    • Best 0
    • Groups 0

    saidalateral

    @saidalateral

    0
    Reputation
    1
    Profile views
    1
    Posts
    0
    Followers
    0
    Following
    Joined Last Online

    saidalateral Unfollow Follow

    Latest posts made by saidalateral

    • Plot results from multiple strategies in strategy-selection.py

      Like many people I imagine, I'm interested in Backtrader as a means of defining and evaluating multiple strategies on historical stock data. I'm fairly new to Python and am hoping to be able to achieve this without having to delve too deep into the subtleties of the programming language.

      The script strategy-selection.py in the samples folder on github is touted as a simple example which runs two different strategies on one dataset.

      But how can I plot results for each strategy, or for a subset of strategies?

      cerebro.plot()

      plots the results of the first strategy, then pauses. When I close the plot window, it plots the next strategy in a new window. I would like to be able to see both at once. I can't seem to find a definitive solution in any previous posts.

      I am using 'idle' as my editor.

      posted in General Code/Help
      S
      saidalateral