For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/

General question related to memory usage and time range



  • Hi, I have a couple questions, I appreciate if someone can help me out.

    Memory usage: I'm running an optimization strategy passing some ranges, what I noticed related to resource usage is that my disk is at top usage and my CPU is at 3%. Is that expected? Will backtrader download the data every optimization run or just for the first time? (I'm running it in a Linux VM in Azure and getting the data from Influx)

    Time range for tests: Usually what is the time range to apply the strategy to see if its working, meaning that it will not take long to run but also will return decent results. 15 days, 1 month, 3 months, more?
    Of course after you see its more or less working a higher range to test would be necessary.

    Thanks!


  • administrators

    @lucas-condé said in General question related to memory usage and time range:

    Memory usage: I'm running an optimization strategy passing some ranges, what I noticed related to resource usage is that my disk is at top usage and my CPU is at 3%. Is that expected?

    Yes. You are using Python. And unless you want to keep the results of the last optimization, each run keeps its own copy.

    Will backtrader download the data every optimization run or just for the first time?

    We don't know what you are doing, difficult to answer.

    Time range for tests: Usually what is the time range to apply the strategy to see if its working, meaning that it will not take long to run but also will return decent results. 15 days, 1 month, 3 months, more?

    Entirely dependent on your chosen timeframe and objectives.



  • @backtrader First, thank you for always helping me out.

    The memory usage is clear now.

    I'm trying to run optimization on 1m timeframe and my objetive is scalping.
    Would 1 month of data be enough for that?

    I'm also thinking of running it on 5m and 15m timeframe aswell, so maybe I would need to go for 2 months and 4 months?


  • administrators

    @lucas-condé said in General question related to memory usage and time range:

    Would 1 month of data be enough for that?

    If your month was a melt-up month like the SP&500 has has in the last few years, your strategy results would probably be biased.

    I would go for different 1-monht scenarios (or 1-week) to make sure that the scalping works in each and every situation. It is also not the same to try scalping with a bank of $1M as to try scalping with a bank of $10K (the latter needs a lot more points to generate the absolute returns you need as a human being)

    @lucas-condé said in General question related to memory usage and time range:

    I'm also thinking of running it on 5m and 15m timeframe aswell, so maybe I would need to go for 2 months and 4 months?

    Same as above. It entirely depends also on how often your strategy trades.