repo32

Spinning Tops

This is my script for a spinning top. It is just another form of a doji. It is an indecision bar. Enjoy.
Open-source script

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.

Disclaimer

The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.

Want to use this script on a chart?
//Created by Robert Nance 7/13/15
//This script is for spinning tops.  I have another script with all the major candlesticks.  This one is to simply identify spinning top candlesticks

stsize=input(.5, minval=.1, title="Spinning Top Size")
study(title = "Spinning Tops", overlay = true)
spinningtop=(open>close) and ((high-low)>(3*(open-close))and(((high-open)/(.001+high-low))< stsize)and (((close-low)/(.001+high-low))< stsize))or
            (close>open) and ((high-low)>(3*(close-open))and(((high-close)/(.001+high-low))< stsize)and (((open-low)/(.001+high-low))< stsize))

plotchar(spinningtop, title="Spinning Top", text='ST', color=yellow, char='+')