** PROFITABLE EA ** --- Help! (I can share my EA for free or pay for changes) - page 3

 
43-21:

Will you please show the performance of your EA? which product or which FX pair you tried?!

Can i get EA in source coding?

Which time GMT u used i trade?

Pls send EA to mail ID - srkalimuthu@gmail.com

Rgds/John, India


Everything you ask for is on first page of this thread!

 
hansjlachmann:

I have rewritten everything in this EA, just for simplicity. This one have fixed stop loss and TP

Works on all instruments

400 codelines reduced to 90. The main problem with this is too high stop loss..

if you are using 5 digit broker the parameteres needs to be 1000 = 100 pips stop loss etc...

parameter MovingAvgOscillatorLimit = 20 for 5 digit and 2 for 4 digit

I did a quick back test on v1.0 and v2.0 for this month only.

v1.0 took 13 trades but v2.0 only took 2 trades. Both were in profit.

I noticed v2.0 did only market orders in one direction only. I prefer to do pending straddle trades or pending one direction trades.

I have attached forward demo test of v1.0 that started this week.

 
Everett:

I did a quick back test on v1.0 and v2.0 for this month only.

v1.0 took 13 trades but v2.0 only took 2 trades. Both were in profit.

I noticed v2.0 did only market orders in one direction only. I prefer to do pending straddle trades or pending one direction trades.

I have attached forward demo test of v1.0 that started this week.

Here is demo results for this week.

 

here is a new version 2.1

Please notice the parameters:

extern int BarsHistoryCount = 100; //no of bars to find high/low

extern double MovingAvgOscillatorLimit = 20; // hardcoded in old versjon 1.0. Did only work for EURJPY . if 5 digit trading platform set to 20, 4 digit set to 2
extern int TakeProfit = 150; //no of points take profit 5 digit trading platform = 150 / 4 digit trading platform = 15
extern double LotSize = 1; //fixed lot size
extern bool StraddleMode = false; //if true, will open two pending sellstop/buystop orders. If False will only open one buy/sell stop-order in the direction of the trading signal
extern bool PartialClose = true; //if false closes the order at TakeProfit, If true closes 1/2 at Take profit and other 1/2 at TakeProfit*3
extern bool UseTradingSession1 = true; //if UseTradingSession1 + UseTradingSession2 + UseTradingSession3 are false (all of them) trading is always allowed
extern int StartTradingSession1HH = 6;
extern int StopTradingSession1HH = 10;
extern bool UseTradingSession2 = false;
extern int StartTradingSession2HH = 14;
extern int StopTradingSession2HH = 18;
extern bool UseTradingSession3 = false;
extern int StartTradingSession3HH = 22;
extern int StopTradingSession3HH = 04;

kind regards

Hans

Files:
tsrv2.1.mq4  8 kb
 

here's the problem...to high stop loss... huge drawdown

Files:
 
hansjlachmann:

here's the problem...to high stop loss... huge drawdown

Thanks for the quick coding, its working better now. I have entered values that work for me. I have not tested trading times yet. Will do after this.

Try this ea with default settings and let me know.

Can you check and make sure ea will not interfere with other ea's?

I have only tested this ea with EURJPY, 1 hour. I do not know results with EURGBP as you tested.

I think we can find a happy middle for stop loss. Possible lowering of stop loss after a variable time by variable pips.

Code changes identified with //** .


My theory for ea.


Once condition found then entry would be straddle of variable candles back from entry condition. The straddle would include a pending pips buffer amount.

The stop loss would be a look back also, possibly a swing high or low. This variable look back would be different from the entry look back.

After trade opened half of trade would be closed when in profit by half of take profit. Stop loss moved to break even.

When in trade look for other entry conditions, and open new ones up to maxtrade number.

That's it.

Files:
tsrv2.2.mq4  8 kb
 

The defalut setting BarsHistoryCount in V2.2 cannot be 8. This is the parameter to search for previous high/low iHighest(NULL,0,MODE_HIGH,BarsHistoryCount,1) find out the support/resistance levels

if your set the parameter to 8 it will only consider the highest/lowest out of the 8 last bars. you need at least 50, i used 100

This version does not interfere with other EA's because is is using if(OrderMagicNumber()!=MAGICMA || OrderSymbol()!=Symbol()) continue;

when looping throgh current orders. version 1.0 didn't do this.

i will try to work more with the EA on sunday and make better stop/loss strategy.

thanks

Hans

 

attached new verion

have implemented the parameters: Candles_for_Entry, Candles_for_SL,Pending_Pips_Buy,Pending_Pips_Sell

removed parameter BarsHistoryCount (replaced by Candles_for_Entry)

i had som problems with error 130 (invalid stop loss)....

Files:
tsrv2.3.mq4  9 kb
 
hansjlachmann:

attached new verion

have implemented the parameters: Candles_for_Entry, Candles_for_SL,Pending_Pips_Buy,Pending_Pips_Sell

removed parameter BarsHistoryCount (replaced by Candles_for_Entry)

i had som problems with error 130 (invalid stop loss)....

Thanks for code

2.3 did not test as well as 2.2.

I think we should go back to 2.2 and add the pending pips for the entry and the expire.

Change the take profit method to this.


Have two take profits, 1st take profit is set by user to be the minimum amount desired. When amount reached, set SL to BE, close half of order. 2nd take profit is also set by user. Another user option of adjustment pips would need to be entered.
Say 2nd take profit is 50 pips and adjustment pips is 20 pips. When 1st take profit is reached and price continues, then when price is 20 pips above BE, SL would be adjusted to lock in half of adjustment pips. In this case SL adjusted to lock in 10 pips. When price goes up to 40 pips then locked in pips would be 20, after 60 pips it would be 30 pips.

extern double First_TP = 24;
extern int Close_percentage = 50; percentage of trade to close for first take profit (from 1% to 100%)
extern double Second_TP = 50;
extern double Adjust_Pips = 20; // when 20 pips past BE, adjust SL to lock in half this amount (10 pips).

Maybe also good to have percentage amount of how much to close trade. Maybe instead of 50% maybe set to 70% or 80%.

 

here's a new V2.3

the only difference from V2.2 is this:

-removed parameter BarsHistoryCount replaced by parameter Candles_for_Entry

-added parameter Candles_for_SL into the stop loss calculation

-parameters Pending_Pips_Buy/Pending_Pips_Sell - buffer pips added on calculation of support/resistance levels

Can you test if this works as well as V2.2 ??

i dont have time to fix the TP/Exit strategy atm. i will get back asap (2-3 days)

Hans

Files:
tsrv2.3_2.mq4  8 kb
Reason: