Topic: Testing with MT4 and BOT

Hi all!

New here..

I would like to ask a few things. Here's some information that will lead to my questions..

I am certain that I want to perform backtests on generated EAs both on BOT and MT4. I am familiar with MT4 and have also Dukascopy tick data that I use. Those are not BO data but FX, however tests can be done on MT4 by using a 0.01 spread, which works okay. I created a random trial EA just to play around and mainly to compare the variance in %itm between MT4 and BOT on the same data, on the same EA. I did not complete the task though, here's why (with questions)..

1) I couldn't define a good range of data on BOT. I converted and uploaded Dukascopy data into .json format (at least I think it was the Dukascopy data that was converted) but I saw no difference. Tried to change maximum bar limit on the code but again, nothing. I even changed the symbol endings as I have no .bo files, and I changed this to UTC+2_00 which is the end of the string of the HST files. Now, I have no idea what's wrong and if anything is wrong but I can't figure out how to increase the data range on BOT. My coding skills aren't great either. My Dukascopy data are from 3/1/14 to today. So, where does the script gets its data from and how can I increase the range of data working on BOT simulator?

2) While running a test on MT4 I remembered that once I had an indicator that by the eye entered signals at the current candle, however due to lag the signal was fired on the next candle, meaning that in reality all results were wrong. What is the case with BOT, is lagging taken into consideration when one is looking at the %itm run on backtest data?

3) While optimising I saw a maximum of a 95% confidence and a varied (much lower) %itm compared to the non-optimised itm%. What is the purpose of the optimisation tool, meaning, should one only consider EAs that at least have a good %itm on a 95% confidence level? What are the optimum settings?I find the optimisation tool on FSB much more 'productive'.

4) I noticed that when performing a test on the MT4 none of its strategy tester fields presented information. I had to go into 'log' and find the specific EA results, then input it into xl etc. Considering the BOT provides no strategy test results that can be saved into a file, apart the trades results, there is a lot of information missing,  i.e. max draw, graph, opt results etc. Additionally, the log file on MT4 provides only the entry point, no exit point, and the itm%. So, I can;t even see the pip difference between entry and exit points. Is there a way to modify the EA and give it the ability to present the relative information appearing in the MT4 strategy tester?

That's all for now. Thank you for reading. Looking forward for some answers!

S

Re: Testing with MT4 and BOT

1) I couldn't define a good range of data on BOT

The process of importing data from MetaTrader is very simple and straightforward.
1. You download the script provided in the BO Tester -> Tools -> Data Import page
2. Run this script on a MetaTrader chart. The script exports the available data for that symbol in files.
3. Drag and drop these files in BO Tester
4. Change the Data Source, Symbol and Period in the Editor.

Please sea a more detailed instruction here:  Data Import

If you have problems on a particular step of the process, please post data file, screenshots or log files. We will examine and fix the problem or will find a workaround. (We created that application from scratch without an analogue and probably we can fix any issue with it or to make it working smoother and better.)

..

N.B.
Please post the separate questions in separate topics. It will make it easier for the other users to find and use the information later.

Re: Testing with MT4 and BOT

2) While running a test on MT4 I remembered that once I had an indicator that by the eye entered signals at the current candle, however due to lag the signal was fired on the next candle, meaning that in reality all results were wrong. What is the case with BOT, is lagging taken into consideration when one is looking at the %itm run on backtest data?

There is no lag in the application or in the exported expert advisors. They execute the signals at the tick the signal is formed. Please attach a strategy and a screenshot and we will find an explanation.

I had an indicator that by the eye entered signals at the current candle, however due to lag the signa

Please note that the software rises signals only when the bar is finally formed and the indicator values are fixed. The app doesn't rise trading signals inside a bar. It rises signals only at the first tick of a new bar. This is by design and is a trademark of our backtesters. This design guarantees 100% compatibility between the trading signals and the backtest on same data. On the other case it would be like the MetaTrader's fake tick mode.

All our applications are created with the primary purpose to provide reliable and save (for the traders) backtest. We do that from 2001 as an alternative to the other "backtesting" software, which have a slightly different purpose.

Re: Testing with MT4 and BOT

3) While optimising I saw a maximum of a 95% confidence and a varied (much lower) %itm compared to the non-optimised itm%. What is the purpose of the optimisation tool, meaning, should one only consider EAs that at least have a good %itm on a 95% confidence level? What are the optimum settings?I find the optimisation tool on FSB much more 'productive'.

Binary Option Tester doesn't include an Optimizer yet. Can you post more detail, strategies and screenshots? We cannot comment and analyse general statements.

Re: Testing with MT4 and BOT

4) I noticed that when performing a test on the MT4 none of its strategy tester fields presented information. I had to go into 'log' and find the specific EA results, then input it into xl etc

MetaTrader is not capable to perform backtest of binary options strategies (neither other software can do it, as we know).
Binary Options Tester was created to cover that problem and to make the difference between the gambling and the professional trading with binary options.

Our Signal experts can simulate a backtest in MetaTrader. This is done with two purposes:
1. Most opinionated traders believe only to MetaTrader. We created that simulations to make them happier.
2. The signal experts show a limited statistical information when run on a MetaTrader tester. When compare that numbers with the BO Tester numbers we ensure that there are no bugs in the experts.

We relay only to the tools we created for us and our users because we know the internals of the math models and we are sure that these apps provide reliable results.

We know that MetaTrader has bugs and design flaws in the backstabbing algorithm. We reported bugs to MetaQutoes several times but no positive results from that. So, the only solution is to make an alternative and reliable tool to do that job. If you have a specific observation for issues, please post as many details as you can and we will find a solution.

Trade Safe!

6 (edited by Stav 2016-09-30 15:45:33)

Re: Testing with MT4 and BOT

The process of importing data from MetaTrader is very simple and straightforward.

I have followed this process and uploaded the json extensions files.

I converted and uploaded Dukascopy data into .json format

The issue is that the data range of the historical data I uploaded was far larger than what the BOT made available for me. The starting day is 01/01/14, where BOT reads bars, and they are far less than the starting date I have data for (01/01/2014). The maximum bar count for all timeframes on the MT4 when running the BO Tester Data Export script is limited to 2048.


How can I increase this? I tried the home button but there is no change. Is this data my Dukascopy data or the data downloaded from the history centre? And if the latter is true then how can I import the Dukascopy data to BOT? Which MT4 folder does the script get the data from? Does the fact that I have made the .HST and .FXT data "READ ONLY" BEFORE using the BO tester Data Export script play a role?

Post's attachments

MT4 Data Bars.gif
MT4 Data Bars.gif 36.14 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Testing with MT4 and BOT

Binary Option Tester doesn't include an Optimizer yet. Can you post more detail, strategies and screenshots? We cannot comment and analyse general statements.

Isn't the Monte Carlo part of optimisation?

The example I use now is just a random generated EA. Under Tools, Monte Carlo, one can see the simulations chart, confidence table, simulations and options tabs. Under options the user must fill the relative tabs of market variation, execution problems and strategy variations. There are some defaults values used. How can one figure out the best values for those settings or at least know if the default settings are realistic. Trial and error here is impossible considering an infinite amount of numbers...

The simulation chart provides the new results, which in most cases reduce the EAs performance and also provide a confidence table. So

should one only consider EAs that at least have a good %itm on a 95% confidence level?
Post's attachments

Monte Carlo.png 24.87 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Testing with MT4 and BOT

MetaTrader is not capable to perform backtest of binary options strategies (neither other software can do it, as we know).
Binary Options Tester was created to cover that problem and to make the difference between the gambling and the professional trading with binary options.



This is true but when there is 0 spread used any data really would do the job, is that correct? All I want is to use MT4 as a second testing mechanism an for ease purposes.

We relay only to the tools we created for us and our users because we know the internals of the math models and we are sure that these apps provide reliable results.

I have no doubt about that. Although on a different matter I would prefer to have a nice graph showing the equity curve, information about %itm, drawdown and all the rest, and have that in a document that I can download evey time I perform a test. MT4 allosw that. BOT allows to download only the trades results. Wouldn't it be nice I if this document included a balance chart, the backtest output under Report, and simulation results?

Saying this reminds me that all the EAs, when tested on MT4 and output the backtest results onto the journal, the results DO NOT include the closing price of the trades. I find this really important, especially for BO. How can this be changed?

Post's attachments

Example Report.gif 44.5 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Testing with MT4 and BOT

If you know of any quick fix via coding please let me know. It's probably just a command that isn't 'printing' on the log.

Thank you

Re: Testing with MT4 and BOT

This is true but when there is 0 spread used any data really would do the job, is that correct? All I want is to use MT4 as a second testing mechanism an for ease purposes.

There is no spread in the Binary Options trading. The broker provides a Payout value in per cents, which determines the profit at a successful trade.

Example.
Lets trade with $10 (called stake) and the Payout level to be 80%.
When you open the deal, you lose the stake.
If the deal ends on profit, the broker returns you the initial stake and gives you also profit = stake * payout. In our case the profit will be $10 * 80% = $8.

MetaTrader doesn't have a concept for payout. Also the profit and loss in forex depends on the difference between the position's close price and the position's open price. This is completely different than the way the BO trading works. It is useless to try backtest BO strategies in MT with the MT tester and the provided from MT stats info and tools. There is no way to see balance and positions in the MT tester, because it cannot close positions in the way BO trading works.

I see you want to confirm the BO Tester results with MT, but this is not possible so far.

BO Tester is the world's first tool for backtesting BO strategies and "unfortunately" a second opinion is not possible. This doesn't mean that BO Tester shows random results smile. You can review the complete trading stats and position chart in the Report page.

Re: Testing with MT4 and BOT

The maximum bar count for all timeframes on the MT4 when running the BO Tester Data Export script is limited to 2048.

I haven't put such limitations in the scripts. There is 20 000 bars limitation, that you can change to whatever number you decide.

You can open the script in the MetaTrader editor and to check or change the bar limitation.

http://s12.postimg.org/65j0ift0d/screenshot_10.png

Re: Testing with MT4 and BOT

Isn't the Monte Carlo part of optimisation?

Monte Carlo is not an optimizer. It is a toll for testing the robustness and the reliability of the strategy.

The BO Tester's Monte Carlo documentation is under construction yet, but you can take a look at the FSB Pro documentation at the topic: Monte Carlo

Re: Testing with MT4 and BOT

Saying this reminds me that all the EAs, when tested on MT4 and output the backtest results onto the journal, the results DO NOT include the closing price of the trades.

BO Tester provides the price at the moment of an option expiration. However, in BO trading the target price (strike) is equal to the position (option) open price. BO Tester reports the strike at the report and also in the exported data.

http://s12.postimg.org/lsa9vt6sd/screenshot_11.png

Re: Testing with MT4 and BOT

I see you want to confirm the BO Tester results with MT, but this is not possible so far.

Not exactly confirm the results, I am sure that what you've build here works, hence I am here smile  I would say that I want to find discrepancies, if any, in data and test EAs in various of brokers and with various data, rather just rely on one broker's data, for obvious reasons.

You can the complete trading stats and position chart in the Report page.

Can you make this report page downloadable? i.e the stats info, balance chart (not too important) and the transactions log into one document (any format)? At this point I can only download the transactions log.

BO Tester reports the strike at the report and also in the exported data.

Yes I am aware. The EAs however do not display the closing price when run on MT4. See picture of the log file on MT4, it only displays the opening price, not the closing price. Is there a quick fix via coding for this so the closing price can be displayed as well?

Post's attachments

MT4 log.png 68.51 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Testing with MT4 and BOT

You can open the script in the MetaTrader editor and to check or change the bar limitation.

Here's a screen shot of the version of the code I have and the changes I made. Please note that I have no .bo", "bo", "." data in my folders. My data are of HST, FXT and CSV type.

Post's attachments

BO Data Exp.png 42.17 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.

Re: Testing with MT4 and BOT

Yes I am aware. The EAs however do not display the closing price when run on MT4.

This is a log of the Alerts. When there is a signal, the EA rises an alert, so we can execute a deal manually. The deal expires alone and we don't have control on the position. Therefore, we don't need an alert for closing it.

Re: Testing with MT4 and BOT

Here's a screen shot of the version of the code I have and the changes I made. Please note that I have no .bo", "bo", "." data in my folders. My data are of HST, FXT and CSV type.

"bo" endings are not important.

..

I see you set 9 999 999 999 for the bar's limit, but as I know the max integer number is 2 147 483 647. Source: https://docs.mql4.com/basis/types/integer

Because MetaTrader is a new and unmatured software, it cannot detect variable overflows yet (We hope MetaQuotes will fix that in the next centuries). Please try with a lower number. Lets say 2147483647.

Re: Testing with MT4 and BOT

This is a log of the Alerts. When there is a signal, the EA rises an alert, so we can execute a deal manually. The deal expires alone and we don't have control on the position. Therefore, we don't need an alert for closing it.

Is execution manual in Signals EA and automated on Trading EA? Are there anyway any possible ways of knowing the close price, that is on MT4 journal?

Re: Testing with MT4 and BOT

Please try with a lower number. Lets say 2147483647.


I will do this then, thank you

Re: Testing with MT4 and BOT

Is execution manual in Signals EA and automated on Trading EA?

Yes. Exactly.

Re: Testing with MT4 and BOT

Are there anyway any possible ways of knowing the close price, that is on MT4 journal?

Yes, there is a simple way.
Add these two lines at the beginning of the ColsePosition function.

   int digits=(int) MarketInfo(_Symbol,MODE_DIGITS);
   PrintFormat("Position closed at " + DoubleToString(closePrice, digits) + " on " + TimeToString(closeTime, TIME_DATE|TIME_MINUTES));

Like that:

http://s18.postimg.org/6q879axw9/screenshot_2016_10_01_at_00_14_15.png

Re: Testing with MT4 and BOT

Stav wrote:

Please try with a lower number. Lets say 2147483647.


I will do this then, thank you

Things were much easier actually. It was only a small change required within MT4. Not sure why I haven't thought about this earlier.


int digits=(int) MarketInfo(_Symbol,MODE_DIGITS);
PrintFormat("Position closed at " + DoubleToString(closePrice, digits) + " on " + TimeToString(closeTime, TIME_DATE|TIME_MINUTES));

Works like a charm - thank you

Post's attachments

MT4 MaxBars Setting.png 64.87 kb, file has never been downloaded. 

You don't have the permssions to download the attachments of this post.