condition for BUY:
1. When close crosses Smoothed HA
2.Close should be in side upper band
3. must be greater than the average
vice versa for sell
this code takes data from HA chart so that it can be applied on all chart type.
and width conditions added for removal of unwanted signals
Alert added so that you can apply alert and check it in real time performance
thanks to The Secret Mindset You tube channel from where I got the idea to convert this into a pine script indicator
smooth HA taken from "Smoothed Heiken Ashi Candles v1" at //@jackvmk
In true TradingView spirit, the author of this script has published it open-source, so traders can understand and verify it. Cheers to the author! You may use it for free, but reuse of this code in a publication is governed by House Rules. You can favorite it to use it on a chart.