Navigation

    Backtrader Community

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/

    Implementing strategies that depend on many lines (1,000+)?

    General Code/Help
    3
    3
    305
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • F
      fakenewsnetwork last edited by

      Is it feasible to backtest and execute a strategy that incorporates 100s or thousands of lines/data-feeds? In the multi-data feed examples like here it appears that you need to add a line for each feed.

      What if my strategy wants to observes ~1,000 different securities with OHLCV and possible more inputs, so 5,000+ lines per timestamp. Is this feasible? If so an example would be much appreciated.

      1 Reply Last reply Reply Quote 0
      • A
        ab_trader last edited by ab_trader

        Feasible for me can be not feasible for you. And vice versa.

        You already posted a link to the example. Leave only price printout on every next() in that example, run it and you will see how much time it takes to run the whole test and how much time it takes to run single next().

        Appreciate if you can share time consumption results of your run.

        • If my answer helped, hit reputation up arrow at lower right corner of the post.
        • Python Debugging With Pdb
        • New to python and bt - check this out
        1 Reply Last reply Reply Quote 0
        • B
          backtrader administrators last edited by

          For sure not in the microsecond range ... but who knows with a daily timeframe. It all depends on what you want to calculate.

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post
          Copyright © 2016, 2017, 2018, 2019, 2020, 2021 NodeBB Forums | Contributors