Forex



Go Back   Forex Trading > Downloads > Expert Advisors - Metatrader 4
Forex Forum Register More recent Blogs Calendar Advertising Others Help






Register
Welcome to Forex-TSD!, one of the largest Forex forums worldwide, where you will be able to find the most complete and reliable Forex information imaginable.

From the list below, select the forum that you want to visit and register to post, as many times you want. It’s absolutely free. Click here for registering on Forex-TSD.

Exclusive Forum
The Exclusive Forum is the only paid section. Once you subscribe, you will get free access to real cutting-edge Trading Systems (automated and not), Indicators, Signals, Articles, etc., that will help and guide you, in ways that you could only imagine, with your Forex trading.
  • Elite Section
    Get access to private discussions, specialized support, indicators and trading systems reported every week.
  • Advanced Elite Section
    For professional traders, trading system developers and any other member who may need to use and/or convert, the most cutting-edge exclusive indicators and trading systems for MT4 and MT5.
See more

Reply
 
Thread Tools Display Modes
  #21 (permalink)  
Old 08-13-2008, 12:04 AM
Senior Member
 
Join Date: Feb 2007
Posts: 176
lcfxtrader is on a distinguished road
Quote:
You're welcome. btw, the original code should have worked, I just re-did it to exclude the use of multiple 'return's (which bugs me!) - are you sure it isn't an OrdersHistoryTotal() problem as described above?
Omelette,

I do not understand what you mean by "OrdersHistoryTotal() problem as described above". The problem I have experienced is that the EA would open the wrong position size after a loss.

EX:

1st trade = .1 lot resulting in a loss

then it would open

2nd trade = .3 lots

It should have been .2 lots
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #22 (permalink)  
Old 08-13-2008, 12:40 AM
Senior Member
 
Join Date: Jan 2006
Posts: 1,119
omelette is on a distinguished road
Quote:
Originally Posted by lcfxtrader View Post
Omelette,

I do not understand what you mean by "OrdersHistoryTotal() problem as described above". The problem I have experienced is that the EA would open the wrong position size after a loss.

EX:

1st trade = .1 lot resulting in a loss

then it would open

2nd trade = .3 lots

It should have been .2 lots
OrdersHistoryTotal() is buggy, meaning it will not work properly when backtesting. Also, when it is used in an EA that is being forward-tested, (such as this one) if there is no closed orders visible in the 'Accounts History' tab, the 'LotSizeFactor' variable (which is causing the problem) will not be set correctly...

That said, I have had a proper look at the code and the problem seems to be a 'recovery' issue, and not the code per-se - so I have restored the original code and added some 'recovery' code! (original post) Making an EA 'robust' to account for 'recovery' problems can be more difficult then writing the EA itself! And there is no guarantee with what I've done here - so let me know how it goes!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #23 (permalink)  
Old 08-13-2008, 02:09 AM
Senior Member
 
Join Date: Feb 2007
Posts: 176
lcfxtrader is on a distinguished road
Omelette,

All the trades opened per the rules except EUR/CHF. It meet the 3 requirements on the candle close (< SMA, < PSAR, 10 day ADR @ 51). The red arrow you see in the pic was a few days ago on the original EA. Any idea why it would not open according to the code? Thanks again for all your help. Would you like to test along with us?

Lcfx
Attached Images
File Type: gif eurchf.gif (66.6 KB, 1285 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #24 (permalink)  
Old 08-13-2008, 03:26 AM
Senior Member
 
Join Date: Jan 2006
Posts: 1,119
omelette is on a distinguished road
I've just realised I do not even know what the strategy is - could you outline exactly what is involved, as it's easier to know what the EA should be doing, rather than trying to work it out from the code - entry conditions I understand, but are you scaling into a position, semi-martingale-style, and waiting until a certain dollar value is achieved, or are losers closed out???

Also, is the EURCHF problem in addition to the lot-sizing bug?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #25 (permalink)  
Old 08-13-2008, 04:19 AM
Senior Member
 
Join Date: Oct 2007
Posts: 235
zomg is on a distinguished road
Does the EA work on IBFX mini account as well as standard? Just wondering if m at the end of pairs will cause it to not work.

Regards. Luk.

Last edited by zomg; 08-13-2008 at 06:13 AM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #26 (permalink)  
Old 08-13-2008, 01:40 PM
Senior Member
 
Join Date: Feb 2007
Posts: 176
lcfxtrader is on a distinguished road
Quote:
omelette
Senior Member Join Date: Jan 2006
Posts: 1,070


I've just realised I do not even know what the strategy is - could you outline exactly what is involved, as it's easier to know what the EA should be doing, rather than trying to work it out from the code - entry conditions I understand, but are you scaling into a position, semi-martingale-style, and waiting until a certain dollar value is achieved, or are losers closed out???

Also, is the EURCHF problem in addition to the lot-sizing bug?
Omelette,

The system is very simple (hence its name). It is based on the daily candle close.

Entry for a short position:

If the candle closes below the SMA (currently set @ 20), below the PSAR (currently set a default), and the previous 10 day ADR is > 50 pips then an entry for a short is made on the open of the next daily candle.

Entry for a long position:

If the candle closes above the SMA (currently set @ 20), above the PSAR (currently set a default), and the previous 10 day ADR is > 50 pips then an entry for a long is made on the open of the next daily candle.

Stop loss & take profit:

I have both of these set to 100 pips giving a 1:1 risk/reward ratio

Money management:

The mm is designed to increase lot size by a factor of 1. It increases the lot size after a loss and decreases it after a win. Just image going up and down on a latter eventually returning to the ground when the job is finished.

Notes:

The system should have only 1 trade open per pair at any given time (contingent on all indicators agreeing of course). A new trade in that pair can't be opened until either the take profit or stop loss has been hit for the current trade. I am counting on our win rate to be 50% or better over the long haul. If this is the case, then our mm will recover the losses along the way.

I hope this summary gives you a good overview on how the SDS - simple daily system works.

Last edited by lcfxtrader; 08-19-2008 at 08:09 PM.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #27 (permalink)  
Old 08-13-2008, 01:47 PM
Senior Member
 
Join Date: Feb 2007
Posts: 176
lcfxtrader is on a distinguished road
Quote:
Originally Posted by zomg View Post
Does the EA work on IBFX mini account as well as standard? Just wondering if m at the end of pairs will cause it to not work.

Regards. Luk.
Luk,

I don't know. I am using a standard IBFX account for testing. Give it a try and report your findings.

Lcfx
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #28 (permalink)  
Old 08-13-2008, 01:57 PM
Senior Member
 
Join Date: Feb 2007
Posts: 176
lcfxtrader is on a distinguished road
Quote:
Also, is the EURCHF problem in addition to the lot-sizing bug?
I don't think so because I deactivated the old EA and loaded your version along with opening a new demo account. It meet the criteria for a short on the last daily candle. I will watch it again tonight and see what happens.

Here's an update on the EA performance.
Attached Images
File Type: jpg SDS 08.13.jpg (167.6 KB, 1231 views)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #29 (permalink)  
Old 08-13-2008, 02:00 PM
Senior Member
 
Join Date: Jan 2006
Posts: 1,119
omelette is on a distinguished road
Thanks, that explain things nicely (and also what SDS stood for )

The EURCHF order you mentioned not opening - is this an additional bug?

Edit: Aha, I see you have just answered!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
  #30 (permalink)  
Old 08-13-2008, 02:07 PM
Senior Member
 
Join Date: Feb 2007
Posts: 176
lcfxtrader is on a distinguished road
Quote:
Originally Posted by omelette View Post
Thanks, that explain things nicely (and also what SDS stood for )

The EURCHF order you mentioned not opening - is this an additional bug?

Edit: Aha, I see you have just answered!
I don't know. The criteria was there to open a short. I doubled checked the open and closed orders and didn't see it. I will watch for the short tonight (0:00 GMT).
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!StumbleUpon this Post!Reddit this Post!Facebook this Post!BlinkList this Post!Google Bookmarks this Post!Yahoo! My Web this Post!
Reply With Quote
Reply

Bookmarks

Tags
daily system, PSAR EA, forex, Forex Daily system, daily, simple daily system, ADR calculator mq4, forex adr calculator, simple daily system ea, sds ea, ADR Calculator, "simple daily system", adr calculator mt4, daily ea forex, SDS_UMM, SDS_UMM_ver1.mq4, adr calculator forex


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
FXiGoR DYNAMIC Breakout system on Daily Average Range iGoR Suggestions for Trading Systems 276 11-14-2009 06:31 AM
Daily ASC Trend system returned +766 pips in Jan kiwifxguy Suggestions for Trading Systems 13 11-13-2009 09:43 AM
simple 5/8 crossover daily chart PeterM Suggestions for Trading Systems 12 06-13-2008 02:13 PM
Daily high-low break system EA lmx2000 Expert Advisors - Metatrader 4 2 12-06-2006 01:00 PM


All times are GMT. The time now is 07:02 AM.



Search Engine Friendly URLs by vBSEO 3.2.0 ©2008, Crawlability, Inc.