JohnScher

STORM - Short On Rising Markets

Category: Strategies By: JohnScher Created: November 29, 2022, 1:35 PM
November 29, 2022, 1:35 PM
Strategies
6 Comments
STORM - Short On Rising Markets

It’s pretty simple.

We take a fast average and a slow average.
We set two filters: the ATR and the time.
Now if the fast average is above the slow average and we get a simple 3 candle reversal we sell.

There is a fifty fifty chance, but this time we win.

//------------------------------------------------------------------
// OnlyShort Strategy on Dax
// Dax 1 Euro Mini
// TimeZone europe, berlin
// TimeFrame 4H
// MainCode : 4HS STORM - ShorT On Rising Markets
// created and coded by JohnScher
//------------------------------------------------------------------

defparam cumulateorders = false // works with true too

once ordersize = 1

//Pentuple Exponential Moving Average
period1 = 50
Period = MAX(Period1, 1)
MA1 = ExponentialAverage[Period](close)
MA2 = ExponentialAverage[Period](MA1)
MA3 = ExponentialAverage[Period](MA2)
MA4 = ExponentialAverage[Period](MA3)
MA5 = ExponentialAverage[Period](MA4)
MA6 = ExponentialAverage[Period](MA5)
MA7 = ExponentialAverage[Period](MA6)
MA8 = ExponentialAverage[Period](MA7)

PEMA = (8 * MA1) - (28 * MA2) + (56 * MA3) - (70 * MA4) + (56 * MA5) - (28 * MA6) + (8 * MA7) - MA8

//Hull Moving Average
period2 = 100
Period2 = MAX(Period2, 1)
HMA = WeightedAverage[ROUND(SQRT(Period2))](2 * WeightedAverage[ROUND(Period2 / 2)](close) - WeightedAverage[Period2](close))

// filter time
tm = openmonth <> 4 and openmonth <> 10
td = opendayofweek >= 2 and opendayofweek <= 5
tt = time >= 090000 and time <= 210000

// conditions
c1 = close > PEMA
c2 = PEMA > HMA

c3 = close < close[1] // 3-candle-revers, could be tested with some bearish candlestick pattern
c4 = close[2] < close[1]

c5 = averagetruerange [5] > 40 // filter, someone could be find betterone

// maincode
if tm and td and tt then
if c1 and c2 and c3 and c4 and c5 then
sellshort ordersize contracts at market
endif
endif

// fifty fifty chance
set stop %loss 2
set target %profit 2

// no trailing, no strategyprofit, no ...
Download
Filename: STORM-ShortOnRisingMarkets.itf
Downloads: 362
JohnScher
JohnScher Veteran
This author is like an anonymous function, present but not directly identifiable. More details on this code architect as soon as they exit 'incognito' mode.
Author’s Profile

Comments

AndyB72
1 year ago
#

Not a great OOS...

Wilko
4 years ago
#

I absolutely love the simplicity of this mean-reversion strategy. Well done!

BenJuice
4 years ago
#

JohnScher, merci de partager ta stratégie. Je suis nouveau dans ce domaine, sur ton code quel est le stop loss ? D'avance merci

JohnScher
4 years ago
#

As a percentage of the price, here 2%. StopLoss as well as TargetProfit. SL and TP come from my basic approach to trading. Every time we have a 50/50 chance to win a trade with the same SL and same TP. In the end over countless trades we have to suffer a loss because of the spread. And now add the conditions at which we enter a trade. If we enter the trade on our conditions, the scales tip in our favor. // fifty fifty chance set stop %loss 2 set target %profit 2

pableitor
4 years ago
#

Thanks for sharing your strategy. Would it be possible to make it work in shorter TF's like 5m or 1m? Rgds

JohnScher
4 years ago
#

With averages you can play around a lot, also in the lower timeframes, there are dozens possibilities. Compare averages here - https://www.prorealcode.com/prorealtime-trading-strategies/optimization-ma-cross-machine-learning/ To keep it simple I use here 2 known averages in default settings and set the filters time and ATR. nothing completly indifferent

ProRealCode ProRealCode
Loading...