TradingView
Crinklebine
Oct 21, 2018 6:51 AM

Candle Type (The Strat) 

Microsoft CorporationNASDAQ

Description

This script identifies the 3 different candle types for use in #TheStrat (see Twitter).

Candle Type 1 - Inside Candle
Candle Type 2- Up or Down Candle
Candle Type 3 - Engulfing Candle

Analysis of the candle types can help you define actionable signals and draw broadening formations.

Release Notes

Set the precision of the plot to zero as the result is binary for the bar type. Removed an unnecessary variable.

Release Notes

Modified colors to work better across both black and white backgrounds.

Release Notes

Added a version number in the configuration menu.
Code cleanup.

Release Notes

Removed version label
Comments
SaraStratSniper
Hey Crinklebine. LOVE the indicator and use it. However, I noticed if the candle is the same price as the low of the previous candle it shows as a 2 and I believe it should show as a 1. For example, say the first candle in a series is a 2 and has a high of 20.10 and a low of 20.00. The next candle has a high of 20.08 and a low of 20.00 (this candle shows up as a 2 instead of a 1). I was wondering if you could update the script so that if the bottom of the candle is equal to or higher than the previous candles low it reads as an inside bar. If not no biggie, but I consider an inside bar to fit entirely inside of the previous candle even with equal lows. Thanks again for all of your contributions.
Crinklebine
@Sabatino84, Thank you. I have open sourced Candle Type on GitHub for a peer review of the code. I will review any pull requests for a future version and you would be free to fork the code under the GNU General Public License v3.0. Here is the link: github.com/Crinklebine/candle-type
Denilson666
Has the Strat been backtested ?
mberbick23
There is a version of this on thinkorswim that plots the "2-Up" numbers above the candle in green and the "2-Down" numbers below the candle in red . By any chance are you able to make that type of modification for a quicker analysis of the two candles?
coininvestor
In your description, candle type 3 should be an outside candle rather than an engulfing candle.

Engulfing candle is determined by the body of the candle.

Outside candle is determined by the wicks of the candle.
Crinklebine
@coininvestor, Yes, I will take a look and confirm the terminology. We want the terminology to be correct. Thank you for the feedback.
Crinklebine
@coininvestor Unfortunately, the Tradingview script publishing system does not allow me to update the initial description. And, since there is no code change to publish a release note is not generated. Hopefully users will read these comments and see that I endorse your naming convention. There is definitely a subtle and important difference between these two candle types. A "3" candle definition is meant to define an "outside candle" including the wicks. Thank you for advising on clarity.
coininvestor
@Crinklebine, Thanks for following up on this.
Heikin-Ashi-Investor
What is best way to set alerts for the appearance of a 3 or 1 bar? Have you played around with this?
stockmarketaddict
WOW awesome...THANKS!!!!!
More