OPEN-SOURCE SCRIPT

PCSPL

Type A Candle:

This candle is labeled "A" if its high price is higher than the high price of the previous candle, and its low price is also higher than the low price of the previous candle.
In simpler terms, the entire candle (both the top and bottom) is above the previous candle.
Type B Candle:

This candle is labeled "B" if its high price is lower than the high price of the previous candle, and its low price is also lower than the low price of the previous candle.
In simpler terms, the entire candle (both the top and bottom) is below the previous candle.
Type C Candle:

This candle is labeled "C" if its high price is higher than the high price of the previous candle, and its low price is lower than the low price of the previous candle.
In simpler terms, this candle has a higher high and a lower low compared to the previous candle, indicating a larger range or volatility.
Type D Candle:

This candle is labeled "D" if its high price is lower than the high price of the previous candle, and its low price is higher than the low price of the previous candle.
In simpler terms, this candle has a lower high and a higher low compared to the previous candle, indicating a smaller range or consolidation.
Candlestick analysis

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 publication is governed by House rules. You can favorite it to use it on a chart.

Want to use this script on a chart?

Disclaimer