OPEN-SOURCE SCRIPT

TechniTrend: CandleMetrics

🟦Overview
The TechniTrend: CandleMetrics Indicator is a powerful tool designed to give traders an in-depth analysis of candlestick structures. This indicator allows users to identify potential reversal points, trend continuations, and other crucial market behaviors by examining key ratios between candle components—such as body, shadow, and overall range—alongside volume conditions. The advanced filtering options offer flexibility for both novice and experienced traders, enabling tailored setups to suit different trading strategies.

🟦Key Features
🔸Customizable Ratios: Set thresholds for Body-to-Range, Shadow-to-Range, Upper Shadow-to-Range, and Lower Shadow-to-Range ratios.
🔸Volume-Based Filters: Integrate volume conditions to strengthen the reliability of signals.
🔸Flexible Conditions: Choose whether filters should work independently or in combination, allowing for precise pattern identification.
🔸Visual Markers: Mark potential signals with a distinct background color and symbols on the chart.
🔸Alerts: Receive notifications for each selected condition, ensuring you never miss an opportunity.

🟦How It Works
The CandleMetrics Indicator operates by analyzing the relationship between different components of each candlestick, combined with volume data to determine the strength of signals. Here’s a detailed breakdown of each feature:

🔸Body to Range Ratio:
This filter compares the size of the candle's body to its total range (from high to low).
Example Setting: If you’re interested in spotting candles with small bodies relative to their total range, you might set the Body-to-Range Ratio to “Less than 0.3.”

🔸Shadow to Range Ratio:
This examines the combined size of both shadows (upper and lower) relative to the entire candle range.
Example Setting: Use a Shadow-to-Range Ratio set to “More than 0.8” to find candles with significant wick lengths, suggesting market indecision.

🔸Upper Shadow to Range Ratio:
This filter assesses the proportion of the upper shadow (wick) in relation to the candle’s full range.
Example Setting: “Less than 0.05” can help identify situations where the upper shadow is minimal, indicating strong downward pressure.

🔸Lower Shadow to Range Ratio:
It measures the lower shadow compared to the entire candle range.
Example Setting: “More than 0.7” is useful for detecting potential rejection patterns at lower prices, hinting at a possible bullish reversal.

🔸Volume Filter:
Integrates volume data to verify the reliability of each candle pattern.
Example Setting: Apply a Volume Filter Length of 100 with an SMA type to smooth volume data over a longer period, filtering out short-term noise and focusing on significant volume shifts.

🟦Combining Filters
The indicator offers an option to Combine Filters. When this setting is enabled, all selected conditions must be met simultaneously for a candle to be marked. If disabled, each condition functions independently, allowing more flexibility in detecting diverse patterns.

🟦Examples & Use Cases
🔸Example 1: Spotting Reversal Opportunities
I used the following configuration to find potential bullish reversals:
Upper Shadow to Range Ratio: “Less than 0.05” – Looking for candles with almost no upper shadow.
Lower Shadow to Range Ratio: “More than 0.7” – Highlighting candles with a significant lower shadow.
Volume Filter Length: 100 with SMA.
This setup effectively highlights candles where price rejection is happening at lower levels, suggesting a potential trend reversal to the upside.

🔸Example 2: Detecting Market Uncertainty
If you want to focus on candles showing market hesitation, try:
Shadow to Range Ratio: “More than 0.85” – Emphasizing long-wick candles that could indicate indecision.
Disable Combine Filters to allow flexibility, marking any candle meeting the above criteria.

🟦Detailed Explanation of Each Option
Here’s a clear and concise breakdown of each option for a better understanding:

1. Body to Range Ratio
Purpose: This ratio shows how significant the candle's body is compared to its overall range. A smaller body-to-range ratio can indicate a potential reversal if the market appears indecisive.
How to Use: Increase the ratio to filter for stronger trend candles; decrease it to identify reversal or indecision candles.
2. Shadow to Range Ratio
Purpose: This filter captures the size of both shadows relative to the candle's total range. A larger ratio often points to market hesitation, while a smaller ratio suggests a decisive move.
How to Use: Adjust this filter to focus on candles with long wicks (indecision) or short wicks (decisiveness).
3. Upper Shadow to Range Ratio
Purpose: Helps to identify candles with strong downward moves by focusing on the upper wick length. A small upper shadow can imply sellers' dominance.
How to Use: Lower the ratio to detect candles with minimal upward rejection.
4. Lower Shadow to Range Ratio
Purpose: Targets candles with strong buying pressure by analyzing the lower shadow. A larger lower shadow may indicate a bullish reversal.
How to Use: Increase the ratio to spot rejection candles with significant lower shadows.
5. Volume Filter
Purpose: Adds a volume component to verify the validity of each candlestick pattern. Higher-than-average volume often signifies the strength of a move.
How to Use: Adjust the filter length and type to smooth out volume fluctuations based on your trading timeframe.

🟦Indicator Alerts
Each filter has its own alert configuration, enabling traders to stay updated on market conditions that meet their selected criteria. You can customize alerts to trigger whenever a condition is met, helping to manage trades even when away from the screen.
candleanalysiscandlepatterncandlepatternscandlesignalCandlestick AnalysiscandlestickanalisysCandlestick analysiscandlestickpatterncandlestickspatternsVolume

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