The Most Profitable Trading Pattern You Will Ever Encounter

Okay, here it is! It looks pretty good.

Here are the conditions which needs to be met in order the generate a signal.

Green: EMA(20) > EMA(50) and RSI(14) > 40 and Stoch(14, 3, 3) < 20 and Stoch k cross d
Red: EMA(20) < EMA(50) and RSI(14) < 60 and Stoch(14, 3, 3) < 80 and Stoch k cross d


It is worth further studying, if you want to add any other filter, or to remove any doubt about the validity of a questionable trade.

Code:

study(“Philip’s Strategy”, shorttitle=“PS”, overlay=false)
smoothK = input(14, minval=1), smoothD = input(3, minval=1)
k = sma(stoch(close, high, low, smoothK), 3)
d = sma(k, smoothD)
a=ema(close, 20)
b=ema(close, 50)
c=rsi(close, 14)
bgcolor(a > b and c > 40 and k < 20 and d < 20 and cross(k, d) ? green : na, transp=0)
bgcolor(a < b and c < 60 and k > 80 and d > 80 and cross(k, d) ? red : na, transp=0)

[QUOTE=“BBalazs;710437”]Okay, here it is! It looks pretty good. Here are the conditions which needs to be met in order the generate a signal. Green: EMA(20) > EMA(50) and RSI(14) > 40 and Stoch(14, 3, 3) < 20 and Stoch k cross d Red: EMA(20) < EMA(50) and RSI(14) < 60 and Stoch(14, 3, 3) < 80 and Stoch k cross d <img src=“301 Moved Permanently”/> It is worth further studying, if you want to add any other filter, or to remove any doubt about the validity of a questionable trade. Code: study(“Philip’s Strategy”, shorttitle=“PS”, overlay=false) smoothK = input(14, minval=1), smoothD = input(3, minval=1) k = sma(stoch(close, high, low, smoothK), 3) d = sma(k, smoothD) a=ema(close, 20) b=ema(close, 50) c=rsi(close, 14) bgcolor(a > b and c > 40 and k < 20 and d < 20 and cross(k, d) ? green : na, transp=0) bgcolor(a < b and c < 60 and k > 80 and d > 80 and cross(k, d) ? red : na, transp=0)[/QUOTE]

Thanks for sharing this BB. I’ve been trading this strategy for a while. I’ve noticed that the higher probability trades come when for a buy signal RSI is above 60 and a sell signal below 40. Could you please test a currency pair with those variables to see what signals are generated? I would do it myself, but I’m no good at programming! :stuck_out_tongue:

Sure, but it is pretty easy actually in TradingView :stuck_out_tongue: You just switch the RSI’s criteria in the bgcolor section. But here it is nevertheless.

study(“Philip’s Strategy”, shorttitle=“PS”, overlay=false)
smoothK = input(14, minval=1), smoothD = input(3, minval=1)
k = sma(stoch(close, high, low, smoothK), 1)
d = sma(k, smoothD)
a=ema(close, 20)
b=ema(close, 50)
[B]c=rsi(close, 14)[/B]
bgcolor(a > b and [B]c > 60[/B] and k < 20 and d < 20 and cross(k, d) ? green : na, transp=0)
bgcolor(a < b and [B]c < 40[/B] and k > 80 and d > 80 and cross(k, d) ? red : na, transp=0)

You just need to copy the code in the pine editor in TradingView, save it and you can access it anytime.


A quick glance at the EURUSD pair. 1 signal out of 5 is right on the money. The others are not exactly.

The attached draft of an MT4 indicator is an enhanced RSI that gives buy/sell signals based on EMAs and Stochastic.

EDIT: New version!

[ul]
[li]v1.00: Same as before, signal will be considered to be valid if Stochastic main line has at least touched the overbought/oversold area.
[/li][li]v1.01: Signal will be considered to be valid if both, Stochastic main line and signal line have been in or at the overbought/oversold area at the same time.
[/li][li]v1.02: Instead of the RSI the distance between the two EMAs is painted. The RSI is now taken into account when buy/sell signals are calculated.
[/li][/ul]

RSI_EMA.zip (1.71 KB)

RSI_EMA.zip (5.07 KB)

Thanks dude, I use tradingview a lot so this is great

The thing is, its stochastic 14,3,1. Both has to go to overbought/oversold. Good luck with your C++.

I like your indicator a lot because, using multi-time frames will give us high-probability trades. So I would switch to weekly and work my way down to the four hours.

If you tell me what you are looking for on the other TFs, I might be able to program it for you.

[B]Note: I updated the code shared earlier. The Stoch settings are now 14,3,1.[/B]

bgcolor(a > b and c > 60 and k < 20 and d < 20 and cross(k, d) ? green : na, transp=0)
bgcolor(a < b and c < 40 and k > 80 and d > 80 and cross(k, d) ? red : na, transp=0

Hello!
I think the rules are that the K of Stochastics need to cross 20 or 80 but not necessarily the D.
So maybe this code is not perfect?

No Gandhi, the code is right.

I managed to create an indicator of my system and I’m very excited about that. Now I don’t we can trade with it because it doesn’t do money management (although I can fix that.)

But I did do backtest on the 4-hour for the last four years, it is the most profitable system indeed. I will share the results later today.

I did not know you are a coding genius :stuck_out_tongue:

I’m not. But I’m amazed by the results!

What are the results?

So here is the first pair. Please note that I coded a robot trading the system, not an indicator. There are five things to note:

  1. The results have no money management applied to them whatsoever. Its 0.1 lots.
  2. I didn’t manage to code my fibonacci exit strategy. So I stuck with a 100-pip trailing stop. Most likely, the fib, would have caught the bigger moves better but that’s ok.
  3. The stochastics crossovers are only valid if they take place within the overbought or oversold area. That’s the only way I managed to code it.
  4. I created a long only robot and a short only robot. That’s the only way I managed to code it.
  5. This is without the RSI filter. This is the main core of my system.


These are the EURUSD long only results. So you see here it lost a total of 850 pips approximately in four years. Now this amount is irrelevant since there is no money management.
Some 57.7% of the trades were winners. the winners to losers ratio was 0.83.

Now what this tells us is that LONG was not the trend in EURUSD over the past four years. And as we all know trends could change. To properly evaluate if this is a good system (and I discussed this before), we apply the kelly formula. The result of this system was a fraction of 0.068. So it is a solid system.

Now let’s move to the short. We all know that short EURUSD was the trend over the past four years, but of course the robot didn’t. It only trades the conditions.


So you can see a total of 3200 pips approximately. Some 67.6% of the trades were winners. The winners to losers ratio was 1.63.

Applying the the kelly formula, we get a fraction of 0.477. To understand what the fractions mean, simply a fraction in positive territory means a system will generate profit. A negative fraction means the system isn’t profitable. will mean this system would yield a profit when traded. A positive fraction of 1 simply means that God or an all-knowing creature is trading. The closer to 1 a system is, the stronger it is.

At the first few pages of my thread I promised to give you a trend-following system that had a high accuracy (unlike the 20% success rate of most trend-following system) while maintaining the high win to loss ratio.

Now the EURUSD backtest results shows I delivered on that promise. And as I share more and more results it will become clear this is the most profitable pattern you will ever encounter.

What a GREAT work you are doing PhilipPirrip!

Thank you!

Nice one Philip! I didn’t know you were using cTrader too :slight_smile:

Hi Philip,
I would like to publish my watchlist for the next week.
Please ,make your comment about it , if you have to add and some other couples,we are looking forward to see.
Of course,I am talking about for H4 strategy.
[B][I]For Long[/I][/B]
AUD\USD
GBP\NZD
GBP\JPY
EUR\NZD
USD\JPY
[B][I]For short[/I][/B]
EUR\USD
EUR\GBP
NZD\JPY
NZD\CHF
Best regards

can you show me a chart picture of your alleged AUDUSD long on the 4HR please?

Sorry I wrote by mistake