Jump to content

Baila


Recommended Posts

  • Replies 125
  • Created
  • Last Reply

Top Posters In This Topic

Guest Jayman007

Listen guys.. zero divide is NOT a show stopper.

 

This just means that you don't have good data. If you have a mathematical equation that involves division (like a ratio) and the denominator (the number on the bottom) is Zero then you have a situation that breaks algebraic math. Try to take any number and divide it by 0 on ANY calculator and you will see what I mean. This is one function that breaks algebra. This is also why Calculus was born (but that is another story).

 

So back to zero divide error...... this just means that the denominator is 0 (without value) probably due to lack of good data. Either download better history or just let it keep running and once it has full data to make it's calculations it will. This has NOTHING to do with 4 or 5 dig brokers.

Edited by Jayman007
Link to comment
Share on other sites

Listen guys.. zero divide is NOT a show stopper.

 

This just means that you don't have good data. If you have a mathematical equation that involves division (like a ratio) and the denominator (the number on the bottom) is Zero then you have a situation that breaks algebraic math. Try to take any number and divide it by 0 on ANY calculator and you will see what I mean. This is one function that breaks algebra. This is also why Calculus was born (but that is another story).

 

So back to zero divide error...... this just means that the denominator is 0 (without value) probably due to lack of good data. Either download better history or just let it keep running and once it has full data to make it's calculations it will. This has NOTHING to do with 4 or 5 dig brokers.

 

I've tick data from Dukascopy. So, the history data shouldn't be the problem. I believe the problem is come from calculation in the EA.

Link to comment
Share on other sites

Guest Jayman007

Alankw88--

 

Are you saying that when you run a backtest that you ONLY get zero divide errors throughout the entire BT and never get any trades?

 

BTW... here is a free tool to test the integrity of your data...

 

http://www.mt4i.com/dataintegrity.aspx

 

Also, tick data from dukas is NOT in mt4 format. You must convert it and that could be where you are introducing problems.

 

ALSO, also, I have seen on numerous times that a perfecting working EA gives zero divide error during the beginning of BT. But after it starts moving fwd in the data it starts taking trades. Some see the zero divide and stop the tests prematurely.

Edited by Jayman007
Link to comment
Share on other sites

yeah good idea to test your data..I have heard tick data from Dukascopy can be very bad. I went through the process of doing tick data to get 99% modeling and found Duka data had holes in it everywhere. I can tell you the calcs in the EA are fine and it does work..
Link to comment
Share on other sites

Guest Jayman007
I agree with 50pips. Data is the #1 cause of divide by zero errors (see my explanation above). If the ea is working then it's obviously not a calculation issue from the EA side of things but rather the data the EA has to calculate from.
Link to comment
Share on other sites

Is someone willing to share a 99% backtest for this EA ?

I tried to backtest using Dukascopy data with no success

 

Same here too. When I backtest others EA on the same data from Dukascopy. No problem at all.

But, I get "zero divide" error when testing Baila robot. It never opened a single trade and the whole journal is full of zero divide error :(

Link to comment
Share on other sites

Guest Jayman007

Could this be a weekend related issue? Spread issue? Let me try and just do a small BT using history data and see what I get.

 

So here is report for history data

 

ANALYSIS OF TICK DATA FOR EURUSD M15
For test starting at : 2011.03.24 12:00:00
-----------------------------------------------------------------------------------------------

No obvious problems found in the tick data.


Summary of data
---------------

First tick:                 2011.03.24 12:00:00
Last tick:                  2011.05.06 23:59:47
Total ticks:                682352
Total bars:                 3024
Avg ticks per bar:          225.6
Avg ticks per minute:       15.0
Avg ticks per second:       0.3
Largest gap between ticks:  899 seconds (exc. weekends)
Trading days:               32
Total days in period:       44
Size of .fxt file:          35488232 bytes   (under 2GB limit)

First price:                1.4124
Last price:                 1.4317
Lowest price:               1.4020
Highest price:              1.4938
Largest bar:                0.0114  (at 2011.05.05 15:30:00)
Biggest jump between ticks: 0.0046  (at 2011.03.28 00:00:00)
Biggest jump between bars:  0.0046  (at 2011.03.28 00:00:00)


Suspicious holes in tick data   (allowing gaps of up to 120 minutes)
-----------------------------

(none)

 

 

Now I'm not getting any zero divide or any other error's. Seems to be trading fine on my BT.

 

http://dl.dropbox.com/u/26606641/Baila.htm

 

mind you my data is not complete but the point is it trades and no error.

Edited by Jayman007
Link to comment
Share on other sites

Alankw88--

 

Are you saying that when you run a backtest that you ONLY get zero divide errors throughout the entire BT and never get any trades?

 

BTW... here is a free tool to test the integrity of your data...

 

http://www.mt4i.com/dataintegrity.aspx

 

Also, tick data from dukas is NOT in mt4 format. You must convert it and that could be where you are introducing problems.

 

ALSO, also, I have seen on numerous times that a perfecting working EA gives zero divide error during the beginning of BT. But after it starts moving fwd in the data it starts taking trades. Some see the zero divide and stop the tests prematurely.

 

Hi Jayman,

 

I followed the steps here from Birt

http://eareview.net/tick-data

 

I backtested on others EA, no problem. But, I get zero divide error when testing on Baila.

Link to comment
Share on other sites

Guest Jayman007
Hi Jayman,

 

I followed the steps here from Birt

http://eareview.net/tick-data

 

I backtested on others EA, no problem. But, I get zero divide error when testing on Baila.

 

Do you let the BT complete? Mine runs for a long time even on my **** data before ever taking a trade.

 

EDIT: Just ran the same BT on sig's 4 digit and 5 digit feed and got no errors and a few trades.

I don't have the time to test out the dukas data on this. I'm not one that is big on BT. I am more about fwd test on demo or live cent account.

 

EDIT2: Looking through the code and not seeing many division with variables in there. One place has to do with accounts that are not USD accounts. By any chance does your account fall under this category?

double GetAccCurrToUSD() {
  double l_bid_0;
  if (gs_180 == "USD") return (1);
  if (gs_180 == "EUR") return (MarketInfo("EURUSD", MODE_BID));
  if (gs_180 == "RUR") {
     l_bid_0 = MarketInfo("USDRUR", MODE_BID);
     if (l_bid_0 == 0.0) return (1 / gd_152);
     return (1 / l_bid_0);

 

Here is another area that could cause this error

 

double Get_RAVI(int a_timeframe_0, int a_period_4, int a_period_8, int a_ma_method_12, int a_applied_price_16, int ai_20) {
  double l_ima_24 = iMA(NULL, a_timeframe_0, a_period_4, 0, a_ma_method_12, a_applied_price_16, ai_20);
  double l_ima_32 = iMA(NULL, a_timeframe_0, a_period_8, 0, a_ma_method_12, a_applied_price_16, ai_20);
  double ld_ret_40 = 100.0 * ((l_ima_24 - l_ima_32) / l_ima_32);
  return (ld_ret_40);

 

If the iMA returns a 0 then l_ima_32=0 and ld_ret_40 will create a zero divide error. Like I mentioned before, this would be caused by lack of data to calculate the iMA.

 

Perhaps your dukas data was only created for 1 TF and this is using a diff TF to calculate the iMA. This would cause your error. To test, create the tick data for EVERY tf for EU and not just the M15. Then run the BT on M15 and see if you still get the error.

Edited by Jayman007
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...