hi guys, i'm trying out for the 1st time writing an EA of my own. it's based on a system i found on another forum. i picked it because it was an extremely easy system (only 2 things to look for), but backtesting shows craptistic results.

here are the rules of the system:

1) find inner bar

2) analyse stochastic(8,3,3)

long: if stochastic < 20 and going up, enter at 2 pips above high of inner bar. stop loss at low of prior bar of inner bar.

short: if stochastic > 80 and going down, enter at 2 pips under low of inner bar. stop loss at high of prior bar of inner bar.

seems simple enough right?

here is my main() function:

alright, i suppose forex wouldn't be hard if an EA as simple as that is a winner. i'm only going for long positions as you can see. but past year testing on EUR/USD, i only won 3.6% of trades.

shouldn't the oversold signal from the stochastic at least give me a higher win percentage?

here are the rules of the system:

1) find inner bar

2) analyse stochastic(8,3,3)

long: if stochastic < 20 and going up, enter at 2 pips above high of inner bar. stop loss at low of prior bar of inner bar.

short: if stochastic > 80 and going down, enter at 2 pips under low of inner bar. stop loss at high of prior bar of inner bar.

seems simple enough right?

here is my main() function:

Inserted Code

// find inner bar if (High[2] > High[1] && Low[2] < Low[1]) { // check stochastics double sto_main = iStochastic(Symbol(), NULL, 8, 3, 3, MODE_SMA, 0, MODE_MAIN, 0); double sto_sig = iStochastic(Symbol(), NULL, 8, 3, 3, MODE_SMA, 0, MODE_SIGNAL, 0); if (sto_main > sto_sig) { // up trend if (sto_main < 20) { // strong signal only double stoploss = Low[2] - (2 * Point); double takeprofit = Ask + (40 * Point); // arbitrary take profit if (!AlreadyBuyOrder()) OrderSend(Symbol(), OP_BUY, 0.01, Ask, 0, stoploss, takeprofit); } }

alright, i suppose forex wouldn't be hard if an EA as simple as that is a winner. i'm only going for long positions as you can see. but past year testing on EUR/USD, i only won 3.6% of trades.

shouldn't the oversold signal from the stochastic at least give me a higher win percentage?