OPEN-SOURCE SCRIPT
Cập nhật Cnagda Pure Price Action

Cnagda Pure Price Action (CPPA) indicator is a pure price action-based system designed to provide traders with real-time, dynamic analysis of the market. It automatically identifies key candles, support and resistance zones, and potential buy/sell signals by combining price, volume, and multiple popular trend indicators.
How Price Action & Volume Analysis Works
This combination typically occurs at strong “accumulation” or support areas:
Sellers push the price down to the lowest point, but aggressive buyers step in with high volume, absorbing supply.

Indicates potential exhaustion of selling and likely shift in market control to buyers.
How to Plan Trades Using Silver Zone:
Watch if price returns to the Silver Zone in the future: It often acts as powerful support.
Bullish entries (buys) can be planned when price tests or slightly pierces this zone, especially if new buy signals occur (like yellow/green candle labels).
Place your stop-loss below the bottom line of the Silver Zone.
Target: Look for the nearest resistance or opposing zone, or use indicator’s bullish label as confirmation.

Extra Tip:
Multiple touches of the Silver Zone reinforce its importance, but if price closes deeply below it with high volume, that’s a caution signal—support may be breaking.
Black Zone – Logic, Reason, and Trade Planning (as CPPA):
Logic & Visualization:
The Black Zone is created when the closing price is the highest in the chosen window and volume is the lowest in that window.
Visually, a large black-colored box/rectangle appears on the chart, along with thick horizontal lines at the top (high) and bottom (low) of the candle, extending to the right.
Reasoning:
This combination signals a strong “distribution” or resistance area:
Buyers push the price up to a local high, but low volume means there is not much follow-through or conviction in the move.
Often marks exhaustion where uptrend may pause or reverse, as sellers can soon step in.
How to Plan Trades Using Black Zone:

If price revisits the Black Zone in the future, it often acts as major resistance.
Bearish entries (sells) are considered when price is near, testing, or slightly above the Black Zone—especially if new sell signals appear (like blue/red candle labels).

Place your stop-loss just above the top line of the Black Zone.
Target: Nearest support zone (such as a Silver Zone) or next indicator’s bearish label.
Extra Tip:
Multiple touches of the Black Zone make it stronger, but if price closes far above with rising volume, be cautious—resistance might be breaking.
Support Line – Logic, Reason, and Trade Planning (as Cppa):
Logic & Visualization:
The Support Line is a dynamically drawn dashed line (usually blue) that marks key price levels where the market has previously shown significant buying interest.
The line is generated whenever a candle forms a high price with high volume (orange logic).
The script checks for historical pivot lows, past support zones, and even higher timeframe (HTF) supports, and then extends a blue dashed line from that price level to the right, labeling it (sometimes as “Prev Support Orange, HTF”).
Reasoning:
This line helps you visually identify where demand has been strong enough to hold price from falling further—essentially a floor in the market used by professional traders.
If price approaches or re-tests this line, there’s a good chance buyers will defend it again.
How to Plan Trades Using Support Line:

Watch for price to approach the Support Line during down moves. If you see a bullish candlestick pattern, buy labels (yellow/green), or other indicators aligning, this can be a high-probability entry zone.

Great for planning stop-loss for long trades: place stops just below this line.
Target: Next resistance zone, Black Zone, or the top of the last swing.
Extra Tip:
Multiple confirmations (support line + Silver Zone + bullish label) provide powerful entry signals.
If price closes strongly below the Support Line with volume, be cautious—support may be breaking, and a trend reversal or deeper correction could follow.
Resistance Line – Logic, Reason, and Trade Planning (from CPPA):
Logic & Visualization:
The Resistance Line is a dynamically drawn dashed line (usually purple or red) that identifies price levels where the market has previously faced significant selling pressure.
This line is created when a candle reaches a high price combined with high volume (orange logic), or from a historical pivot high/resistance,
The script also tracks higher timeframe (HTF) resistance lines, labeled as “Prev Resistance Orange, HTF,” and extends these dashed lines to the right across the chart.
Reasoning:
Resistance Lines are visual markers of “supply zones,” where buyers previously failed, and sellers took control.
If the price returns to this line later, sellers may get active again to defend this level, halting the uptrend.
How to Plan Trades Using Resistance Line:
Watch for price to approach the Resistance Line during up moves. If you see bearish candlestick patterns, sell labels (blue/red), or bearish indicator confirmation, this becomes a strong shorting opportunity.

Perfect for placing stop-loss in short trades—put your stop just above the Resistance Line.
Target: Next support zone (Silver Zone) or bottom of the last swing.

If the price breaks above with high volume, avoid shorting—resistance may be failing.
Extra Tip:
Multiple resistances (Resistance Line + Black Zone + bearish label) make short signals stronger.
Choppy movement around this line often signals indecision; wait for a clear rejection before entering trades.
Bullish / Bearish Label – Logic, Reason, and Trade Planning:
Logic & Visualization:
The indicator constantly calculates a "Bull Score" and a "Bear Score" based on several factors:
Trend direction from price slope
Confirmation by popular indicators (RSI, ADX, SAR, CMF, OBV, CCI, Bollinger Bands, TWAP)
Adaptive scoring (higher score for each bullish/bearish condition met)
If Bull Score > Bear Score, the chart displays a green "BULLISH" label (usually below the bar).
If Bear Score > Bull Score, the chart displays a red "BEARISH" label (usually above the bar).
If neither dominates, a "NEUTRAL" label appears.
Reasoning:
The labels summarize complex price action and indicator analysis into a simple, actionable sentiment cue:
Bullish: Majority of conditions indicate buying strength; trend is up.
Bearish: Majority signals show selling pressure; trend is down.
How to Use in Trade Planning:
Use the Bullish label as confirmation to enter or hold long (buy) positions, especially if near support/Silver Zone.
Use the Bearish label to enter/hold short (sell) positions, especially if near resistance/Black Zone.
For best results, combine with candle color, volume analysis, or other labels (yellow/green for buys, blue/red for sells).
Avoid trading against these labels unless you have strong confluence from zones/support levels.
Yellow Label (Buy Signal) – Logic, Reason & Trade Planning:
Logic & Visualization:
The yellow label appears below a candle (label.style_label_up, yloc.belowbar) and marks a potential buy signal.
Script conditions:
The candle must be a “yellow candle” (which means it’s at the local lowest close, not a high, with normal volume).
Volume is decreasing for 2 consecutive candles (current volume < previous volume, previous volume < second previous).
When these conditions are met, a yellow label is plotted below the candle.
Reasoning:
This scenario often marks the end of selling pressure and start of possible accumulation—buyers may be stepping in as sellers exhaust.
Decreasing volume during a local price low means selling is slowing, possibly hinting at a reversal.
How to Trade Using Yellow Label:
Entry: Consider buying at/just above the yellow-labeled candle’s close.

Stop-loss: A bit below the candle’s low (or Silver Zone line, if present).
Target: Next resistance level, Black Zone, or chart’s bullish label.
Extra Tip:
If the yellow label is found at/near a Silver Zone or Support Line, and trend is “Bullish,” the setup gets even stronger.
Avoid trading if overall indicator shows “Bearish.”
Green Label (Buy with Increasing Volume) – Logic, Reason & Trade Planning:
Logic & Visualization:
The green label is plotted below a candle (label.style_label_up, yloc.belowbar) and marks a strong buy signal.
Script conditions:
The candle must be a “yellow candle” (at the local lowest close, normal volume).
Volume is increasing for 2 consecutive candles (current volume > previous volume, previous volume > second previous).
When these conditions are met, a green label is plotted below the candle.
Reasoning:
This scenario signals that buyers are stepping in aggressively at a local price low—the end of a downtrend with strong, rising activity.
Increasing volume at a price low is a classic sign of accumulation, where institutions or large players may be buying.
How to Trade Using Green Label:
Entry: Consider buying at/just above the green-labeled candle’s close for a momentum-based reversal.
Stop-loss: Slightly below the candle’s low, or the Silver Zone/support line if present.
Target: Nearest resistance zone/Black Zone, indicator’s bullish label, or next swing high.
Extra Tip:
If the green label is near other supports (Silver Zone, Support Line), the setup is extra strong.
Use confirmation from Bullish labels or trend signals for best results.
Green label setups are suitable for quick, high momentum trades due to increasing volume
Blue Label (Sell Signal on Decreasing Volume) – Logic, Reason & Trade Planning:
Logic & Visualization:
The blue label is plotted above a candle (label.style_label_down, yloc.abovebar) as a potential sell signal.
Script conditions:
The candle is a “blue candle” (local highest close, but not also lowest, and volume is neither highest nor lowest).
Volume is decreasing over 2 consecutive candles (current volume < previous, previous < two ago).
When these match, a blue label appears above the candle.
Reasoning:
This typically signals buyer exhaustion at a local high: price has gone up, but volume is dropping, suggesting big players may not be buying any more at these levels.
The trend is losing strength, and a reversal or pullback is likely.
How to Trade Using Blue Label:
Entry: Look to sell at/just below the candle with the blue label.
Stop-loss: Just above the candle’s high (or above the Black Zone/resistance if present).
Target: Nearest support, Silver Zone, or a swing low.
Extra Tip:
Blue label signals are stronger if they appear near Black Zones or Resistance Lines, or when the general market label is "Bearish."
As with buy setups, always check for confirmation from trend or volume before trading aggressively.
Blue Label (Sell Signal on Decreasing Volume) – Logic, Reason & Trade Planning:
Logic & Visualization:
The blue label is plotted above a candle (label.style_label_down, yloc.abovebar) as a potential sell signal.
Script conditions:
The candle is a “blue candle” (local highest close, but not also lowest, and volume is neither highest nor lowest).
Volume is decreasing over 2 consecutive candles (current volume < previous, previous < two ago).
When these match, a blue label appears above the candle.
Reasoning:
This typically signals buyer exhaustion at a local high: price has gone up, but volume is dropping, suggesting big players may not be buying any more at these levels.
The trend is losing strength, and a reversal or pullback is likely.
How to Trade Using Blue Label:
Entry: Look to sell at/just below the candle with the blue label.
Stop-loss: Just above the candle’s high (or above the Black Zone/resistance if present).
Target: Nearest support, Silver Zone, or a swing low.
Extra Tip:
Blue label signals are stronger if they appear near Black Zones or Resistance Lines, or when the general market label is "Bearish."
As with buy setups, always check for confirmation from trend or volume before trading aggressively.
Here’s a summary of all key chart labels, zones, and trading logic of your Price Action script:
Best Practices:
if Any Question, Suggestion Feel free to ask
Disclaimer:
All information provided by this indicator is for educational and analysis purposes only, and should not be considered financial advice.
How Price Action & Volume Analysis Works
- Silver Zone – Logic, Reason, and Trade Planning
- Logic & Visualization:
- The Silver Zone is created when the closing price is the lowest in the chosen window and volume is the highest in that window.
- Visually, a large silver-colored box/rectangle appears on the chart.
- Thick horizontal lines (top and bottom) are drawn at the high and low of that candle/bar, extending to the right.
- Reasoning:
This combination typically occurs at strong “accumulation” or support areas:
Sellers push the price down to the lowest point, but aggressive buyers step in with high volume, absorbing supply.
Indicates potential exhaustion of selling and likely shift in market control to buyers.
Watch if price returns to the Silver Zone in the future: It often acts as powerful support.
Bullish entries (buys) can be planned when price tests or slightly pierces this zone, especially if new buy signals occur (like yellow/green candle labels).
Place your stop-loss below the bottom line of the Silver Zone.
Target: Look for the nearest resistance or opposing zone, or use indicator’s bullish label as confirmation.
Extra Tip:
Multiple touches of the Silver Zone reinforce its importance, but if price closes deeply below it with high volume, that’s a caution signal—support may be breaking.
Black Zone – Logic, Reason, and Trade Planning (as CPPA):
Logic & Visualization:
The Black Zone is created when the closing price is the highest in the chosen window and volume is the lowest in that window.
Visually, a large black-colored box/rectangle appears on the chart, along with thick horizontal lines at the top (high) and bottom (low) of the candle, extending to the right.
Reasoning:
This combination signals a strong “distribution” or resistance area:
Buyers push the price up to a local high, but low volume means there is not much follow-through or conviction in the move.
Often marks exhaustion where uptrend may pause or reverse, as sellers can soon step in.
How to Plan Trades Using Black Zone:
If price revisits the Black Zone in the future, it often acts as major resistance.
Bearish entries (sells) are considered when price is near, testing, or slightly above the Black Zone—especially if new sell signals appear (like blue/red candle labels).
Place your stop-loss just above the top line of the Black Zone.
Target: Nearest support zone (such as a Silver Zone) or next indicator’s bearish label.
Extra Tip:
Multiple touches of the Black Zone make it stronger, but if price closes far above with rising volume, be cautious—resistance might be breaking.
Support Line – Logic, Reason, and Trade Planning (as Cppa):
Logic & Visualization:
The Support Line is a dynamically drawn dashed line (usually blue) that marks key price levels where the market has previously shown significant buying interest.
The line is generated whenever a candle forms a high price with high volume (orange logic).
The script checks for historical pivot lows, past support zones, and even higher timeframe (HTF) supports, and then extends a blue dashed line from that price level to the right, labeling it (sometimes as “Prev Support Orange, HTF”).
Reasoning:
This line helps you visually identify where demand has been strong enough to hold price from falling further—essentially a floor in the market used by professional traders.
If price approaches or re-tests this line, there’s a good chance buyers will defend it again.
How to Plan Trades Using Support Line:
Watch for price to approach the Support Line during down moves. If you see a bullish candlestick pattern, buy labels (yellow/green), or other indicators aligning, this can be a high-probability entry zone.
Great for planning stop-loss for long trades: place stops just below this line.
Target: Next resistance zone, Black Zone, or the top of the last swing.
Extra Tip:
Multiple confirmations (support line + Silver Zone + bullish label) provide powerful entry signals.
If price closes strongly below the Support Line with volume, be cautious—support may be breaking, and a trend reversal or deeper correction could follow.
Resistance Line – Logic, Reason, and Trade Planning (from CPPA):
Logic & Visualization:
The Resistance Line is a dynamically drawn dashed line (usually purple or red) that identifies price levels where the market has previously faced significant selling pressure.
This line is created when a candle reaches a high price combined with high volume (orange logic), or from a historical pivot high/resistance,
The script also tracks higher timeframe (HTF) resistance lines, labeled as “Prev Resistance Orange, HTF,” and extends these dashed lines to the right across the chart.
Reasoning:
Resistance Lines are visual markers of “supply zones,” where buyers previously failed, and sellers took control.
If the price returns to this line later, sellers may get active again to defend this level, halting the uptrend.
How to Plan Trades Using Resistance Line:
Watch for price to approach the Resistance Line during up moves. If you see bearish candlestick patterns, sell labels (blue/red), or bearish indicator confirmation, this becomes a strong shorting opportunity.
Perfect for placing stop-loss in short trades—put your stop just above the Resistance Line.
Target: Next support zone (Silver Zone) or bottom of the last swing.
If the price breaks above with high volume, avoid shorting—resistance may be failing.
Extra Tip:
Multiple resistances (Resistance Line + Black Zone + bearish label) make short signals stronger.
Choppy movement around this line often signals indecision; wait for a clear rejection before entering trades.
Bullish / Bearish Label – Logic, Reason, and Trade Planning:
Logic & Visualization:
The indicator constantly calculates a "Bull Score" and a "Bear Score" based on several factors:
Trend direction from price slope
Confirmation by popular indicators (RSI, ADX, SAR, CMF, OBV, CCI, Bollinger Bands, TWAP)
Adaptive scoring (higher score for each bullish/bearish condition met)
If Bull Score > Bear Score, the chart displays a green "BULLISH" label (usually below the bar).
If Bear Score > Bull Score, the chart displays a red "BEARISH" label (usually above the bar).
If neither dominates, a "NEUTRAL" label appears.
Reasoning:
The labels summarize complex price action and indicator analysis into a simple, actionable sentiment cue:
Bullish: Majority of conditions indicate buying strength; trend is up.
Bearish: Majority signals show selling pressure; trend is down.
How to Use in Trade Planning:
Use the Bullish label as confirmation to enter or hold long (buy) positions, especially if near support/Silver Zone.
Use the Bearish label to enter/hold short (sell) positions, especially if near resistance/Black Zone.
For best results, combine with candle color, volume analysis, or other labels (yellow/green for buys, blue/red for sells).
Avoid trading against these labels unless you have strong confluence from zones/support levels.
Yellow Label (Buy Signal) – Logic, Reason & Trade Planning:
Logic & Visualization:
The yellow label appears below a candle (label.style_label_up, yloc.belowbar) and marks a potential buy signal.
Script conditions:
The candle must be a “yellow candle” (which means it’s at the local lowest close, not a high, with normal volume).
Volume is decreasing for 2 consecutive candles (current volume < previous volume, previous volume < second previous).
When these conditions are met, a yellow label is plotted below the candle.
Reasoning:
This scenario often marks the end of selling pressure and start of possible accumulation—buyers may be stepping in as sellers exhaust.
Decreasing volume during a local price low means selling is slowing, possibly hinting at a reversal.
How to Trade Using Yellow Label:
Entry: Consider buying at/just above the yellow-labeled candle’s close.
Stop-loss: A bit below the candle’s low (or Silver Zone line, if present).
Target: Next resistance level, Black Zone, or chart’s bullish label.
Extra Tip:
If the yellow label is found at/near a Silver Zone or Support Line, and trend is “Bullish,” the setup gets even stronger.
Avoid trading if overall indicator shows “Bearish.”
Green Label (Buy with Increasing Volume) – Logic, Reason & Trade Planning:
Logic & Visualization:
The green label is plotted below a candle (label.style_label_up, yloc.belowbar) and marks a strong buy signal.
Script conditions:
The candle must be a “yellow candle” (at the local lowest close, normal volume).
Volume is increasing for 2 consecutive candles (current volume > previous volume, previous volume > second previous).
When these conditions are met, a green label is plotted below the candle.
Reasoning:
This scenario signals that buyers are stepping in aggressively at a local price low—the end of a downtrend with strong, rising activity.
Increasing volume at a price low is a classic sign of accumulation, where institutions or large players may be buying.
How to Trade Using Green Label:
Entry: Consider buying at/just above the green-labeled candle’s close for a momentum-based reversal.
Stop-loss: Slightly below the candle’s low, or the Silver Zone/support line if present.
Target: Nearest resistance zone/Black Zone, indicator’s bullish label, or next swing high.
Extra Tip:
If the green label is near other supports (Silver Zone, Support Line), the setup is extra strong.
Use confirmation from Bullish labels or trend signals for best results.
Green label setups are suitable for quick, high momentum trades due to increasing volume
Blue Label (Sell Signal on Decreasing Volume) – Logic, Reason & Trade Planning:
Logic & Visualization:
The blue label is plotted above a candle (label.style_label_down, yloc.abovebar) as a potential sell signal.
Script conditions:
The candle is a “blue candle” (local highest close, but not also lowest, and volume is neither highest nor lowest).
Volume is decreasing over 2 consecutive candles (current volume < previous, previous < two ago).
When these match, a blue label appears above the candle.
Reasoning:
This typically signals buyer exhaustion at a local high: price has gone up, but volume is dropping, suggesting big players may not be buying any more at these levels.
The trend is losing strength, and a reversal or pullback is likely.
How to Trade Using Blue Label:
Entry: Look to sell at/just below the candle with the blue label.
Stop-loss: Just above the candle’s high (or above the Black Zone/resistance if present).
Target: Nearest support, Silver Zone, or a swing low.
Extra Tip:
Blue label signals are stronger if they appear near Black Zones or Resistance Lines, or when the general market label is "Bearish."
As with buy setups, always check for confirmation from trend or volume before trading aggressively.
Blue Label (Sell Signal on Decreasing Volume) – Logic, Reason & Trade Planning:
Logic & Visualization:
The blue label is plotted above a candle (label.style_label_down, yloc.abovebar) as a potential sell signal.
Script conditions:
The candle is a “blue candle” (local highest close, but not also lowest, and volume is neither highest nor lowest).
Volume is decreasing over 2 consecutive candles (current volume < previous, previous < two ago).
When these match, a blue label appears above the candle.
Reasoning:
This typically signals buyer exhaustion at a local high: price has gone up, but volume is dropping, suggesting big players may not be buying any more at these levels.
The trend is losing strength, and a reversal or pullback is likely.
How to Trade Using Blue Label:
Entry: Look to sell at/just below the candle with the blue label.
Stop-loss: Just above the candle’s high (or above the Black Zone/resistance if present).
Target: Nearest support, Silver Zone, or a swing low.
Extra Tip:
Blue label signals are stronger if they appear near Black Zones or Resistance Lines, or when the general market label is "Bearish."
As with buy setups, always check for confirmation from trend or volume before trading aggressively.
- Silver Zone: Powerful support zone. Created at lowest close + highest volume. Best for buy entries near its lines.
- Black Zone: Strong resistance zone. Created at highest close + lowest volume. Ideal for short trades near its levels.
- Support Line: Blue dashed line at historical demand; buyers defend here. Look for bullish setups when price approaches.
- Resistance Line: Purple/red dashed line at supply; sellers defend here. Great for bearish setups when price nears.
- Bullish/Bearish Labels: Summarize trend direction using price action + multiple indicator confirmations. Plan buys, holds on bullish; sells, shorts on bearish.
- Yellow Label: Buy signal on decreasing volume and local price low. Entry above candle, stop below, target next resistance.
- Green Label: Strong buy on increasing volume at a price low. Entry for momentum trade, stop below, target next zone.
- Blue Label: Sell signal on dropping volume and local price high. Entry below candle, stop above, target next support.
Best Practices:
- Always combine zone/label signals for higher probability trades.
- Use stop-loss near zones/lines for risk management.
- Prefer trading in the trend direction (bullish/bearish label agrees with your entry).
if Any Question, Suggestion Feel free to ask
Disclaimer:
All information provided by this indicator is for educational and analysis purposes only, and should not be considered financial advice.
Phát hành các Ghi chú
Added Trendline For Better Trade DecisionMã nguồn mở
Theo đúng tinh thần TradingView, người tạo ra tập lệnh này đã biến tập lệnh thành mã nguồn mở để các nhà giao dịch có thể xem xét và xác minh công năng. Xin dành lời khen tặng cho tác giả! Mặc dù bạn có thể sử dụng miễn phí, nhưng lưu ý nếu đăng lại mã, bạn phải tuân theo Quy tắc nội bộ của chúng tôi.
Thông báo miễn trừ trách nhiệm
Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.
Mã nguồn mở
Theo đúng tinh thần TradingView, người tạo ra tập lệnh này đã biến tập lệnh thành mã nguồn mở để các nhà giao dịch có thể xem xét và xác minh công năng. Xin dành lời khen tặng cho tác giả! Mặc dù bạn có thể sử dụng miễn phí, nhưng lưu ý nếu đăng lại mã, bạn phải tuân theo Quy tắc nội bộ của chúng tôi.
Thông báo miễn trừ trách nhiệm
Thông tin và ấn phẩm không có nghĩa là và không cấu thành, tài chính, đầu tư, kinh doanh, hoặc các loại lời khuyên hoặc khuyến nghị khác được cung cấp hoặc xác nhận bởi TradingView. Đọc thêm trong Điều khoản sử dụng.