
You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
Client Terminal / Strategy Tester / Operation of the Strategy Tester / Forward Testing
Thank you.
Yes, from this link.
http://www.metatrader5.com/ru/terminal/help/tester/tester_using/forward_testing.
I found the answer to my second question. However, there are NO answers to the first and third questions.
I would like to have them too.
I want to know the results and ratios of other traders. As my results are very alarming. I am a scientist in the field of automatic control and modelling of non-stationary processes, which includes also a graph of price movement in the market. I have been modelling non-stationary processes for many years and the way the tester works in no way fits into my years of experience. Something is wrong here. Either I use the tester incorrectly or it does not work properly. Let's find out together.
My backtest strictly following the optimization period shows 200% of the profit that we had during optimization with the same parameters. However, when choosing other optimization parameters and testing during the optimization period, we will get several times less profit. That should not be the case. That is why I have some questions.
Well, it's not up to me, as they say, "Whatever I can" (c). I'm far from the topic itself. Try searching the forum, maybe where forward testing has already been discussed. Or, if you think the topic is very important, create a new thematic branch. Otherwise, questions will get lost in general branch.
There are reference materials in the terminal too. F1.
Made a very dumb thing to do.
I took the body of Custom Moving Average indicator and put MFI buffer inside.
I changed the price.
I made you an expert, just an indicator and a comment to verify.
Thanks again for your messages.
Instead of question marks I put PositionSelect(_Symbol) with value true. It didn't help.
Question. What can I change minimally - to be able to set close conditions?The article about the Expert Advisor https://www.mql5.com/ru/articles/100 mentions conditions for opening positions, but it doesn't discuss conditions for closing positions.
Instead of question marks I put PositionSelect(_Symbol) with value true. It didn't help.
Question. What can I change to the minimum - to be able to set closing conditions?You have a return after Alert. Position probably isn't closing because of this return. Please take it away and try again.
However, another question arose on the question marks part.
On the algorithm.
Under appropriate conditions + no position - the position is opened, and under other conditions and the presence of an open position - the open position is closed.
If I'm not mistaken - existence of a position, namely Buy_opened
equal to one - causes alert and return (returns to the beginning), and equal to zero - opens Buy order.
Question. What should I write instead of question marks - the condition of an open order, so that the EA does not open a position (in my case, it opens a sell order) ?
At the moment I have also prescribed Buy_opened, because the conditions of this definition are related to PositionSelect(_Symbol)
I understand that the questions don't mean anything, as it is possible to quickly try out all possible logical options and test, but the problem is that the tester bug doesn't allow me to do this, but there is an opportunity to actually diagnose on M1 in real trading mode.
...
I understand that the questions don't mean anything as you can quickly try out all the possible logical options and test, but the problem is that the tester bug doesn't allow me to do that, but there is an opportunity to actually diagnose on M1 in real trading mode.
I don't quite understand your question.
And what bug in the tester did you find that prevents you from running the test?
I don't quite understand your question.
What is the bug in the tester that prevents you from running the test?
About the question. What should we write instead of the question marks to make the Expert Advisor "understand" that there is an open position and not open an order!
Described earlier, or in the indicator branch. Dema referring to the MFI indicator handle - is not displayed in the MFI window, and therefore - the Expert Advisor does not work. The same goes for MA, AMA.
About the question. What should we write instead of question marks so that the EA "sees" that there is an open position and does not open an order!
If there is a position (PositionSelect(_Symbol)) and all other conditions are met, then close the position. If return from your example is not removed, the condition should look like this
which means if there is no position, then exit. If not exit, the program will execute the code that comes after this block.
But I would put check for presence/absence of position before closing condition checks.