Market Watch Does not follow Strategy Tester

 

Hi.

I am working with strategy tester (for the first time) while the market is off, and I noticed market watch shows a fixed value (bid & ask & time) no matter what the strategy tester is showing. For example when stratey tester shows 1.44640, for GBPUSD (1M), Market Watch only shows 1.35495 (Bid) and 1.355521 (Ask). The time shown in Market Watch is also DEAD and not following strategy tester (all marketwatch values seem to refer to the last REAL tick, not the Historical data from Strategy Tester). As a result, when I refer to 

Ask

or

Bid
prices in my code, I only get the fixed numbers from Market Watch, not the values from the Strategy Tester. How can I make Market Watch, follow Strategy tester prices just like it would do during market hours?


The Fundamentals of Testing in MetaTrader 5
The Fundamentals of Testing in MetaTrader 5
  • www.mql5.com
What are the differences between the three modes of testing in MetaTrader 5, and what should be particularly looked for? How does the testing of an EA, trading simultaneously on multiple instruments, take place? When and how are the indicator values calculated during testing, and how are the events handled? How to synchronize the bars from different instruments during testing in an "open prices only" mode? This article aims to provide answers to these and many other questions.
 
sm.Ghassemizadeh: I am working with strategy tester (for the first time) while the market is off, and I noticed market watch shows a fixed value (bid & ask & time) no matter what the strategy tester is showing. For example when stratey tester shows 1.44640, for GBPUSD (1M), Market Watch only shows 1.35495 (Bid) and 1.355521 (Ask). The time shown in Market Watch is also DEAD and not following strategy tester (all marketwatch values seem to refer to the last REAL tick, not the Historical data from Strategy Tester). As a result, when I refer to or prices in my code, I only get the fixed numbers from Market Watch, not the values from the Strategy Tester. How can I make Market Watch, follow Strategy tester prices just like it would do during market hours?

When I run visual tests on MT5, the "Market Watch" panel put up by the "Strategy Tester Visualization" window, updates correctly and shows the prices change as they should.

So, please show screenshots of your setup explaining at issue, as you must be doing something wrong. Also show a screenshot of your settings tab of the Strategy Tester.

 
Fernando Carreiro #:

When I run visual tests on MT5, the "Market Watch" panel put up by the "Strategy Tester Visualization" window, updates correctly and shows the prices change as they should.

So, please show screenshots of your setup explaining at issue, as you must be doing something wrong. Also show a screenshot of your settings tab of the Strategy Tester.

Thank you Fenando. I have just attached a screenshot of the problem.
Files:
MarketWatch.jpg  316 kb
 
sm.Ghassemizadeh #:
Thank you Fenando. I have just attached a screenshot of the problem.
MT4 question on MT4 forum section please. You are wasting people time.
 
sm.Ghassemizadeh #: Thank you Fenando. I have just attached a screenshot of the problem.

That is MT4, not MT5. You posted in the MT5 sections of the forum.

On MT4, the MarketWatch panel only shows data from for Live feed. It is not updated from the Strategy Tester. To see the tester values, you will have to us a "Comment()" function or some other form of display function, to show those values on the chart.

 
sm.Ghassemizadeh #:
Thank you Fenando. I have just attached a screenshot of the problem.

Topics concerning MT4 and MQL4 have their own section.

In future please post in the correct section.

I have moved your topic to the MQL4 and Metatrader 4 section.

Reason: