Sti - page 13

 

OK. Here is an update to the STI EA that I have been testing.

I have decided that this is a good EA even for this week with the following currency pairs and settings:

NO Trailing Stop for any currency pairs:

EURUSD (TP: 20, SL: 30)

GBPUSD (TP: 20, SL: 30)

USDJPY (TP: 40, SL: 30)

USDCHF (TP: 20, SL: 30)

USDCAD (TP: 20, SL: 30)

NZDUSD (TP: 20, SL: 30)

Possibly

AUDUSD (TP: 20, SL 30)

We could play around with a TP: 60 or so but I think that 20-25 TP is about right. I have also played around with a higher SL and it appears that 30 is about right because if it gets stopped out many times it will open up another trade right away and get you profit.

Anyway, it has been a hard week for this EA. I started the EA in the middle of the week with all currency pairs and decided midstream to filter out the less traded ones.

NewDigital or anyone else, one command that I would like to have added to his EA is a command to close all positions at 20:00 GMT on Friday as to not keep any open positions over the weekend. The reason for this is because sometimes the currency gaps over the weekend and it will usually recover. This EA will usually see that gap and immediate put in an order (long or short) so that we can capitalize on that gap.

Files:
 

Here is the same statement above except categorized according to currency types to see which ones will stay and which ones will go.

By the way, I started with a setting of all currency pairs at:

TP: 60

SL: 30

But I noticed that the EA just couldnt handle that so I decided to change the settings and it appears to be working out pretty well.

Files:
 
holyguy7:
Here is the same statement above except categorized according to currency types to see which ones will stay and which ones will go.

By the way, I started with a setting of all currency pairs at:

TP: 60

SL: 30

But I noticed that the EA just couldnt handle that so I decided to change the settings and it appears to be working out pretty well.

I will post my statements tomorrow. Just to compare. Because I am using different settings.

 

I have noticed that the H4 timeframe seems to be golden. It does not trade as much as the M15 or H1 but it is more stable during news and non-news times. I believe this is golden.

Settings are as follows that appear to work fairly well for me:

Take Profit: 30

Stop Loss: 30

No Trailing Stop

Here are the following currency pairs these work best on:

EURUSD, GBPUSD, USDJPY, USDCAD, AUDUSD, USDCHF

Interesting, when the pairs were running this last week as a result of NEWS, I would reach my take profit and then the EA would immediately open another order in the same direction and would make money off that.

H4 timeframe seems safer for news and overall more reliable according to early tests. I am still playing around with exact settings for TP and SL but in general, I think around 30/30 is good and one only needs to get over 50% correct to break even so it is safer. However, it looks like I could get at least 66% correct using this EA with those settings.

 

I am still having some hope for M15 timeframe. Anyway tomorrow we will see the statements with/without timefilter.

If not so will use some of your settings you may suggest.

 

How is the calculation of the bars done?

Hi Manager,

Great EA! I want to use it live (I'm a student, need to help pay for school) but I'd like to understand how it works.

I know you've said its complicated to calculate the bars manually, which is why you wrote an EA for it.

Can you explain to me how the calculation of the bars are done?

Thanks

Mike

mikey[at]college.ucla.edu

 

Settings

Thank you very much for your contribution, holyguy.

I've some questions.

Which ea and what setting are you using, what about the filters CCI and Stch?

Please add one more favor and let us know.

Regards,

SFX

holyguy7:
OK. Here is an update to the STI EA that I have been testing.

I have decided that this is a good EA even for this week with the following currency pairs and settings:

NO Trailing Stop for any currency pairs:

EURUSD (TP: 20, SL: 30)

GBPUSD (TP: 20, SL: 30)

USDJPY (TP: 40, SL: 30)

USDCHF (TP: 20, SL: 30)

USDCAD (TP: 20, SL: 30)

NZDUSD (TP: 20, SL: 30)

Possibly

AUDUSD (TP: 20, SL 30)

We could play around with a TP: 60 or so but I think that 20-25 TP is about right. I have also played around with a higher SL and it appears that 30 is about right because if it gets stopped out many times it will open up another trade right away and get you profit.

Anyway, it has been a hard week for this EA. I started the EA in the middle of the week with all currency pairs and decided midstream to filter out the less traded ones.

NewDigital or anyone else, one command that I would like to have added to his EA is a command to close all positions at 20:00 GMT on Friday as to not keep any open positions over the weekend. The reason for this is because sometimes the currency gaps over the weekend and it will usually recover. This EA will usually see that gap and immediate put in an order (long or short) so that we can capitalize on that gap.
 
hackrat:
Hi Manager,

Great EA! I want to use it live (I'm a student, need to help pay for school) but I'd like to understand how it works.

I know you've said its complicated to calculate the bars manually, which is why you wrote an EA for it.

Can you explain to me how the calculation of the bars are done?

Thanks

Mike

mikey[at]college.ucla.edu

Hey Mikey... he likes it!

Here is how I understand the algorithm to be. Let's look at the code for more explanation.

for (int k=1; k<=20; k++){ // sets the subject comparison bar. It will look at bars from most recent

// to +20 eg. starting at bar 4 then 5,6,7,8,9,...24.

UpPD[k]=True;

DnPD[k]=True;

PDmax[k]=High[N1+k];

PDmin[k]=Low[N1+k];

for (int d=1; d<=N1; d++){

if (PDmax[k]>High[N1+k+d] && UpPD[k]==True) { // looks for a higher high up to 3 bars back but higher must be true for each bar.

if (PDmin[k]<Low[N1+k-d] && UpPD[k]==True){// looks for a lower low up to 3 bars forward. see above

UpPD[k]=True; // BEAR bar

}

else

UpPD[k]=False;

}

else

UpPD[k]=False;

if (PDmax[k]>High[N1+k-d] && DnPD[k]==True){// looks for a higher high up to 3 bars forward.

if (PDmin[k]<Low[N1+k+d] && DnPD[k]==True) {//looks for a lower low up to 3 bars back.

DnPD[k]=True; //BULL bar

}

else

DnPD[k]=False;

}

else

DnPD[k]=False;

if (UpPD[k]==True && skUp<N2){// if it found a BEAR BAR then....setting open price...

skUp=skUp+1; // will reset the price a max of (N2 value)

if (minmin==0 || minmin>Low[N1+k] ) minmin=Low[N1+k]; // ...price = the low of the original subject bar or lowest subject bar that meets the BEAR criteria

}

if (DnPD[k]==True && skDn<N2){//reverse of BEAR criteria

skDn=skDn+1;

if (maxmax==0 || maxmax<High[N1+k] ) maxmax=High[N1+k];

}

if (UD==0 && DnPD[k])UD=1; //BULL Criteria -OK to proceed

if (UD==0 && UpPD[k])UD=2; //BEAR Criteria -OK to proceed

}

}

string comm=Cmt(Period());

if ( UD==1 && maxmax<=Bid ) {// If Bull crieria ok AND the quote is greater than the high of the Highest Bull bar in relation to the subject then OK to SHORT

if ( UD==2 && minmin >= Ask ) {// Reverse of BULL ^

Stage 1: Starting from the first for loop, we are looking for the most recent bar (starting 4 bars back to 24 bars back) to meet Stage 2 criteria.

Stage 2: Looks for a BEAR (High is higher than previous 2/ Low is lower than Following 2) or BULL bar (Low is lower than previous 2 / High is higher than the following 2. Once it identifies the earliest instance of the criteria met it then looks to set the price. Eg. If there is a BEAR bar the price is Marked at the Low of the subject bar. Then it continues to look back through the rest of the 24 periods and if it finds another BEAR bar it re-Marks the price to the low of that bar if the low is lower than previously marked. It will only Mark and re=Mark the price a maximum number of times which is determined by the value of (x<N2).

Stage 3: When the price meets or exceeds the Mark AND the most recent bar criteria align the EA will place the trade. Eg. Most recent Bear Bar AND the current price is lower than the Low of the lowest subject BEAR bar THEN a LONG order is placed. PHEW... say that 10 times fast

So, when it's all 'said and done'... It looks for the most recent bull/bear bar then sets the price and Opens the appropriate order at the price which was determined.

The problem is that orders are counter trend. This EA works great in whip-saw conditions, but not trending.

To the best of my analytical abilities this is how I understand the algorithm to work. I hope this helps...

Manager, am I correct?

 

Some SET up Problems ??

Hi Holyguy7 and Manager,

I guess I have some problemns in the Setup or the parameters.

See the attached chart - lost out most of the trades using the EA STI4_0_3.mq4.

Any advise.

Thanks

humnle Trader.

holyguy7:
There is a certain brilliance to this EA, but it needs to be improved during the trending times. Nothing comes to mind exactly because of the way it works. I was thinking that perhaps sticking some kind of a filter would help out. I know that Nicholishen added Scholastics to the EA to help. I have not been able to test it properly as it seems that he has added almost too many additions to the EA.

Anyway, here is the latest "yet to be seen improvement" to the EA. I hope that it helps.

I have had some success with this EA this week with certain currency pairs. Currency pairs that have made a profit this week are:

EURUSD, GBPUSD, USDJPY, USDCHF, USDCAD (possibly AUDUSD and NZDUSD)

I use the H4 chart with settings that are:

TP: 60

SL: 30

No Trailing Stop

I started at the beginning of the week and at first it was off to a good start then it lost started to lose the last day or two. I am now up just a little from the beginning of the week. After studying the trades, I discovered that the other currency pairs which I was also testing were what were losing the money for me. Those currency pairs are:

EURJPY, EURCHF, EURGBP, GBPJPY

I will give a statement at the end of the week but I noticed that it dipped down just below what I started with and appears now to be headed in the right direction.

Anyway, here is the "improvement" by Nicholishen. Please test on demo before going live.
Files:
 

Manager

One thing that I noticed in your version 2 is that the criteria for open trades is different from the criteria to draw arrows on the chart. The difference is in the init() , the code for the 2nd for loop verifies that the subject bar is high/lower than the previous/following 2 bars. In the OpenOrder() it only verifies that it meets the criteria, compared against only the immediate bars following and preceeding the subject.

Is that by design?

Reason: