Script tries to capture the length of trends. It calculates an SMA and then determines the slope of the SMA using a simple momentum function. From there it counts bars from when the slope changed directions last. The lime green line is the count from when the slope changed. The yellow line is the average time of a trend. The white line is "trying" to capture the...
The indicator paints the bar colours based on the average open and average close for past N days.
if average close is above average open, the bars are coloured green, otherwise they are coloured red
It can be used as a general trend filter on weekly, daily bars. even on intraday timeframes, this would work well and give a sense of the current trend direction.
Here is an adaptation of TTM_Trend I coded. It's all pretty self explanatory. Aqua = buy and red = sell.
There's only one setting to tweak and it's the look-back for highest and lowest.
I have found that this indicator gives signals at almost identical areas to the TTM_Trend but tend to actually be a little more efficient (earlier buy/sell signals), although I...
// Copyright by Randalll.com v1.0 09/03/2016
// This indicator provides 5 Exponential Moving Averages.
// Works well on 1D,4H,1H TF
// To be used with traditional trend following strategies.
// If 50/100/200 trending in same direction. Then buy/sell
// with trend direction....