Results 1 to 5 of 5
 0 Attachment(s)    

Thread: Code to Backtest Quicker

  1. #1
    Junior Member
    Join Date
    May 2009
    Posts
    4

    Cool Code to Backtest Quicker

    Hello

    Is there any code that could speed up backtesting.......or can be added to speed things up

  2. #2

    Default

    Try to optimize your code:
    1. Calculate custom indicators once and save their value in variable, instead of calculating them several times.

    If you'll upload the code I may speed it up a bit.
    FXCode Inc.
    Expert Advisor Developer

  3. #3

    Default

    Quote Originally Posted by FXCode View Post
    Try to optimize your code:
    1. Calculate custom indicators once and save their value in variable, instead of calculating them several times.

    If you'll upload the code I may speed it up a bit.
    hy
    i'm not a coder.
    could you explain what do you mean? but not in english but an example
    indi must be calculate at every moment for test conditions, so haw can save it?
    in every ea is :
    a=icustom(0,0,"nameof indi",parameters,nb_buffor, nb_bar)
    it is no corect ?

  4. #4

    Default

    Using iCustom within an EA can slow the EA down considerably as it may be performing a lot of unecessary calculations at every price tick for bars that are not needed within the EA.

    If possible you should always extract parts of the indicator code into the EA to just return a value for the few bar shifts that are needed.

  5. #5

    Default

    Quote Originally Posted by jezzer1961 View Post
    Using iCustom within an EA can slow the EA down considerably as it may be performing a lot of unecessary calculations at every price tick for bars that are not needed within the EA.

    If possible you should always extract parts of the indicator code into the EA to just return a value for the few bar shifts that are needed.
    thanks for answer. Jezz
    you right, but probably he thought about something else.
    How is your 's ea work now? can I see their live statement on your's www ?

Similar Threads

  1. How to backtest EAs ?
    By ddock in forum Expert advisors backtesting
    Replies: 35
    Last Post: 07-28-2017, 09:59
  2. Backtest: 99% Quality
    By starger in forum Manual systems statements
    Replies: 3
    Last Post: 12-20-2011, 09:15
  3. I would like your opinion on its backtest
    By fitopo in forum Expert advisors backtesting
    Replies: 0
    Last Post: 01-06-2011, 10:25
  4. EA Backtest Q&A
    By fairylord in forum Expert advisors backtesting
    Replies: 0
    Last Post: 12-11-2009, 15:42
  5. How to code ea to backtest 2 or more TF at same time?
    By jialinc in forum MQL programming
    Replies: 2
    Last Post: 05-10-2009, 07:24

Tags for this Thread

backtest, backtesting, indicator, indicators, live, test

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •