Allows for Smoothing with different values for Up and Down Trend.
Ability to Plot to see Trend Filter
//Created by Chrismoody on 7/22/2014 By Request for user lucalucious //Modified Heikinashi with EMA Filter... //Choice To Plot EMA Trend Is Based Off Of study(title = "CM_Modified_Heik_Trend_Bars", shorttitle="CM_TrendBars",overlay=true) note = input(false, title="Lower Numbers = More Sensitive to Price Change...Higher Numbers = Less Sensitive") uema = input(34, minval=1, maxval=50, title="EMA UpTrend") dema = input(34, minval=1, maxval=50, title="EMA DownTrend") shema = input(false, title="Show EMA Trend is Based On?") haclose = (open + high + low + close)/4 haopen = na(haopen) ? (open + close)/2 : (haopen + haclose) / 2 upEma = ema(haclose, uema) downEma = ema(haopen, dema) emaAvg = (upEma + downEma)/2 heikUpColor() => hlc3 >= emaAvg heikDownColor() => hlc3 < emaAvg col = hlc3 >= emaAvg ? lime : hlc3 < emaAvg ? red : white barcolor(heikUpColor() ? lime: heikDownColor() ? red : na) plot(shema and emaAvg ? emaAvg : na, title="EMA UpTrend", style=line, linewidth=3, color=col)
First off.. TV (and us) are fortunate to have guys like you around here.. :)
Entering and exiting trades based on HA alone is difficult as it doesn't show the actual price bars. This script hugely resolves that issue.
I have slightly modified your script to add:
1. Smoothing of EMA that is displayed on the chart
2. Detect additionally that there are no down wicks (up wicks for short) on the HA bars.
Makes it even more effective!