My TRO EAs

Moderator: moderators

User avatar
newschool
rank: 150+ posts
rank: 150+ posts
Posts: 489
Joined: Fri Aug 21, 2009 2:26 am
Reputation: 1
Gender: Male

Postby newschool » Wed Oct 14, 2009 12:58 am

Bredin,
I now use the last 3sema value as the s/l, as this is more valuable than a standard price because it indeed represent a resistance/support of the current market condition like you wrote.

I also found the way to make the backtesting 10 times faster, the problem is the 3zzsema indicator calculates the whole tick history. You have to manually change the indicator code by simply putting a numeric value as "240" instead of the all pink colored "Bars" variables. In this example the indicator will calculate a little more than the last week in H1.

dennis,
you should remove your code and post the mq4 file. At first glance I see two missing parameters in the iCustom: iCustom(NULL,PERIOD_H1,"3_Level_ZZ_Semafor",false,"ahooha.wav",5,13,34,.......


I was pretty much busy with university, but I will update very soon.. (I am at version 12 of the EA).

Please add www.kreslik.com to your ad blocker white list.
Thank you for your support.

User avatar
Patch
rank: 500+ posts
rank: 500+ posts
Posts: 941
Joined: Sat Jan 06, 2007 6:13 pm
Reputation: 0
Location: Virginia
Real name: Jeff
Gender: Male
Contact:

Postby Patch » Wed Oct 14, 2009 2:09 am

dennis_m1965

I am thrilled to see you are programming an EA on the 3Semafors !!!

Wish I could help.

Patch
In VA

PS when you compile the mt4 code, does it come out with any error? When you set it up on the chart, do you get the smiley face and green hat and green circle with the arrow head in it?
ENOUGH being a Yalie for me Back to the Sea. "What i can lose, i can win" "YES YOU CAN" - dragon33 -"Pick one method and one pair and stick with them until you master it. "The choice is yours - success or failure." TRO

dennis_m1965
rank: <50 posts
rank: <50 posts
Posts: 3
Joined: Tue Dec 16, 2008 7:34 pm
Reputation: 0
Gender: Male

Postby dennis_m1965 » Wed Oct 14, 2009 2:38 pm

See above:

Removed code added mq4. The code compiles and can be added to the chart but never trades.

As a side topic I talked to 3clipz he is thinking build a of EA the breakout of 5 SEMA for GJ.

Dennis

User avatar
bredin
rank: 1000+ posts
rank: 1000+ posts
Posts: 1033
Joined: Mon Feb 16, 2009 10:41 pm
Reputation: 7
Gender: None specified
Contact:

Postby bredin » Tue Oct 20, 2009 7:54 am

newschool wrote:Bredin,
I now use the last 3sema value as the s/l, as this is more valuable than a standard price because it indeed represent a resistance/support of the current market condition like you wrote.

I also found the way to make the backtesting 10 times faster, the problem is the 3zzsema indicator calculates the whole tick history. You have to manually change the indicator code by simply putting a numeric value as "240" instead of the all pink colored "Bars" variables. In this example the indicator will calculate a little more than the last week in H1.


When I cut the sem indi down for my dtb template i used a value of 3 times [sema period], which works well for 3semas. I still feel that including the sema code into the ea itself will make a big difference as you can make it calculate *only* the 3semas.

You can import the CountZZ function straight from the 3lzz sema indi, and adjust the Bars val as youve already done before.

Cheers
G.

User avatar
bredin
rank: 1000+ posts
rank: 1000+ posts
Posts: 1033
Joined: Mon Feb 16, 2009 10:41 pm
Reputation: 7
Gender: None specified
Contact:

Postby bredin » Tue Oct 20, 2009 7:57 am

dennis_m1965 wrote:Any ideas on why this code wont trade?


congrats, youve used a decompiler to make your code almost unreadable.

Good luck with your problem.

Cheers
G.

Please add www.kreslik.com to your ad blocker white list.
Thank you for your support.

dennis_m1965
rank: <50 posts
rank: <50 posts
Posts: 3
Joined: Tue Dec 16, 2008 7:34 pm
Reputation: 0
Gender: Male

Postby dennis_m1965 » Tue Oct 20, 2009 3:41 pm

bredin wrote:
dennis_m1965 wrote:Any ideas on why this code wont trade?


congrats, youve used a decompiler to make your code almost unreadable.

Good luck with your problem.

Cheers
G.
I re-posted re-compiled code. Sorry I am new to this.. Do you mean the code isn't commented or?

Dennis

User avatar
bredin
rank: 1000+ posts
rank: 1000+ posts
Posts: 1033
Joined: Mon Feb 16, 2009 10:41 pm
Reputation: 7
Gender: None specified
Contact:

Postby bredin » Wed Oct 21, 2009 1:20 am

dennis_m1965 wrote:
bredin wrote:
dennis_m1965 wrote:Any ideas on why this code wont trade?


congrats, youve used a decompiler to make your code almost unreadable.

Good luck with your problem.

Cheers
G.
I re-posted re-compiled code. Sorry I am new to this.. Do you mean the code isn't commented or?

Dennis


I mean this:
int start() {
double ld_unused_0;
bool li_8;
bool li_12;
bool li_16;
double l_icustom_20;
double l_icustom_28;
double l_icustom_36;
double l_icustom_44;
double l_icustom_52;
double l_icustom_60;
double l_icustom_68;
double l_icustom_76;
double l_icustom_84;
double l_icustom_92;
double l_icustom_100;
double l_icustom_108;
double l_icustom_116;
double l_icustom_124;
if (TimeCurrent() <= D'08.06.2009 04:30') {
handleProfitLock();
if (TotalTrades() > 0 && !Enter.Multiple.Positions) return;
ld_unused_0 = 1;
if (!Digits.4) ld_unused_0 = 10;
l_icustom_20 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 0, 1);
l_icustom_28 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 1, 1);
l_icustom_36 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 2, 1);
l_icustom_44 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 3, 1);
l_icustom_52 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 4, 1);
l_icustom_60 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 5, 1);
l_icustom_68 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 0, 0);
l_icustom_76 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 1, 0);
l_icustom_84 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 2, 0);
l_icustom_92 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 3, 0);
l_icustom_100 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 4, 0);
l_icustom_108 = iCustom(NULL, PERIOD_H1, "3_Level_ZZ_Semafor_TRO_MODIFIED_VERSION", 0, 5, 13, 34, "1,3", "8,5", "13,8", 140, 141, 142, 5, 0);
if (l_icustom_20 != 0.0 || l_icustom_28 != 0.0 || l_icustom_36 != 0.0 || l_icustom_44 != 0.0 || l_icustom_52 != 0.0 || l_icustom_60 != 0.0 || l_icustom_68 != 0.0 ||
l_icustom_76 != 0.0 || l_icustom_84 != 0.0 || l_icustom_92 != 0.0 || l_icustom_100 != 0.0 || l_icustom_108 != 0.0) {
li_8 = TRUE;
if (l_icustom_20 < iClose(NULL, PERIOD_H1, 1) || l_icustom_28 < iClose(NULL, PERIOD_H1, 1) || l_icustom_36 < iClose(NULL, PERIOD_H1, 1) || l_icustom_44 < iClose(NULL, PERIOD_H1, 1) ||
l_icustom_52 < iClose(NULL, PERIOD_H1, 1) || l_icustom_60 < iClose(NULL, PERIOD_H1, 1) || l_icustom_68 < iClose(NULL, PERIOD_H1, 1) || l_icustom_76 < iClose(NULL, PERIOD_H1, 1) ||
l_icustom_84 < iClose(NULL, PERIOD_H1, 1) || l_icustom_92 < iClose(NULL, PERIOD_H1, 1) || l_icustom_100 < iClose(NULL, PERIOD_H1, 1) || l_icustom_108 < iClose(NULL, PERIOD_H1, 1)) {
li_12 = TRUE;
li_16 = FALSE;
}
if (l_icustom_20 > iClose(NULL, PERIOD_H1, 1) || l_icustom_28 > iClose(NULL, PERIOD_H1, 1) || l_icustom_36 > iClose(NULL, PERIOD_H1, 1) || l_icustom_44 > iClose(NULL, PERIOD_H1, 1) ||
l_icustom_52 > iClose(NULL, PERIOD_H1, 1) || l_icustom_60 > iClose(NULL, PERIOD_H1, 1) || l_icustom_68 > iClose(NULL, PERIOD_H1, 1) || l_icustom_76 > iClose(NULL, PERIOD_H1, 1) ||
l_icustom_84 > iClose(NULL, PERIOD_H1, 1) || l_icustom_92 > iClose(NULL, PERIOD_H1, 1) || l_icustom_100 > iClose(NULL, PERIOD_H1, 1) || l_icustom_108 > iClose(NULL, PERIOD_H1, 1)) {
li_12 = FALSE;
li_16 = TRUE;
}
}
if (li_8) {
l_icustom_116 = iCustom(Symbol(), 0, "TRO_DYNAMIC_FIBS_SR_Trail", 0, 0, 0, 0, 0, 10, 80, 1, "Courier New", 12, 0, 0, 1, 1, 0, 300, 5, 0, 5, 20, 255, 255, 255, 255, 255, 255, 255, 255, 2, 3, 119, 3, 3, 0, 3, 3, 0, 2, 0);
l_icustom_124 = iCustom(Symbol(), 0, "TRO_DYNAMIC_FIBS_SR_Trail", 0, 0, 0, 0, 0, 10, 80, 1, "Courier New", 12, 0, 0, 1, 1, 0, 300, 5, 0, 5, 20, 255, 255, 255, 255, 255, 255, 255, 255, 2, 3, 119, 3, 3, 0, 3, 3, 0, 3, 0);
Comment("H1 Semafor Long: ", li_12,
"\nH1 Semafor Short: ", li_16,
"\nTRODynamicLg: ", l_icustom_124,
"\nTRODynamicSr: ", l_icustom_116);
if (Close[0] >= l_icustom_124 && li_12) buy();
if (Close[0] <= l_icustom_116 && li_16) sell();
}
}
return (0);
}

Id love to help, but dont want to spend a couple of hours going through this code, which has clearly been generated with a decompiler- probably ex4 _to_mp4.

If you want help you'll need to post your original code, with its original, more helpful var names and comments.

Cheers
G

dgobin
rank: <50 posts
rank: <50 posts
Posts: 2
Joined: Wed Oct 21, 2009 9:07 pm
Reputation: 0
Gender: None specified

Postby dgobin » Thu Oct 22, 2009 12:55 pm

I am interested in studying the Semaphor indicator. I have downloaded and installed sema-version5 to test it. On MetaTrader (v.4; build 225), I can choose it as a custom indicator and can attach it to the chart, but the indicator is a no go when the chart is called up after saving the template. Is v.5 a stand alone or just an update to a base version I need to install 1st?

User avatar
newschool
rank: 150+ posts
rank: 150+ posts
Posts: 489
Joined: Fri Aug 21, 2009 2:26 am
Reputation: 1
Gender: Male

Postby newschool » Sun Nov 08, 2009 8:16 pm

bredin, why do you use decompiled code, while I provide the mq4 source in the first post?

dgobin, EA are not indicators. Yes they can be attached to a chart but thats only for live testing. You should use the "strategy tester" to perfom back-testing. The version 5 is trading reversal -according- to the sema indicator.

============================update

I am concerned about trading with default settings of the 3sema. Basically the strategy is working yes, but it particular trends and price pattern. For example the month of september on EU was very positive for me, but many other months made several losses using only the 3sema strategy.

Part of this is because of support / resistance level are not really present intraday in forex since the players or the price movement is continually pushing them. I also think the periods used by the indicator are too small for any TF lower than D1.
Also like someone mentionned, there is a difficulty added in playing reversal versus breakouts.


Basically I am taking a break on my developpement of the sema EA, BUT I have many other strategies actually in testing. I updated the first post with many of them. I still believe in the future of EAs!

I have now created a new thread where I will code for free your strategy = http://kreslik.com/forums/viewtopic.php?p=29991

User avatar
bredin
rank: 1000+ posts
rank: 1000+ posts
Posts: 1033
Joined: Mon Feb 16, 2009 10:41 pm
Reputation: 7
Gender: None specified
Contact:

Postby bredin » Mon Nov 09, 2009 1:33 am

that code is pasted straight from the file downloaded from the post by dennis_m1965 who wanted help getting 'his code' working.

Cheers
G

Please add www.kreslik.com to your ad blocker white list.
Thank you for your support.


Return to “MetaTrader”