Simplified supertrend (without volatility component ATR)

Category: Indicators By: verdi55 Created: January 19, 2018, 9:48 PM
January 19, 2018, 9:48 PM
Indicators
2 Comments

This supertrend does not use a multiple of current average true range (ATR) as the distance to median prices. Instead, the distance of the supertrend line to median prices is only a fraction of the current price (close * factor).

In sideward phases, when average prices do not change, this supertrend will stay constant. The “normal” supertrend (using ATR) will reduce its distance to the median price in sideward phases, when volatility and ATR decrease.

This simplified supertrend can give better results in certain cases, for example in long-term charts, when prices show highly different values falling in a very broad range (e.g. DAX prices between 4000 and 13500).

The indicator behaves more like a traditional trailing stop, because volatility is not considered. The risk of curve-fitting and over-optimization is reduced, because only one adaptable parameter (“factor”) is used.

As always, it should be tried out in every single instance by optimizing a simple trading system whether this indicator or the “normal” supertrend work better.

The indicator should be added to the price window by selecting “settings price – add indicator”. You can colour the indicator or change line thickness yourself using the box “settings simplified supertrend”.

ONCE direction = 1
ONCE STlongold = 0
ONCE STshortold = 1000000000000

factor = 0.005

indicator1 = medianprice

indicator3 = close

indicator2 = indicator3 * factor

STlong = indicator1 - indicator2

STshort = indicator1 + indicator2

If direction = 1 and STlong < STlongold then
 STlong = STlongold
endif

If direction = -1 and STshort > STshortold then
 STshort = STshortold
endif

If direction = 1 and indicator3 < STlong then
 direction = -1
endif

If direction = -1 and indicator3 > STshort then
 direction = 1
endif

STlongold = STlong

STshortold = STshort

If direction = 1 then
 ST = STlong
else
 ST = STshort
endif

Return ST as "simplified Supertrend"

Download
Filename: simplified-Supertrend-w-o-ATR.itf
Downloads: 701
verdi55 Veteran
Currently debugging life, so my bio is on hold. Check back after the next commit for an update.
Author’s Profile

Comments

Logo Logo
Loading...