Smart Candlestick Pattern Filter [MarkitTick]💡 This Script is a sophisticated technical analysis tool designed to identify, grade, and display over 40 distinct candlestick formations based on a proprietary strength and context filtering system. Unlike standard pattern finders that often clutter charts with conflicting signals, this script utilizes a hierarchy logic to display only the most significant pattern detected on any given candle, ensuring chart clarity and actionable data.
● Originality and Utility
The primary utility of this script lies in its filtering engine. Standard indicators often flag every minor Doji or Spinning Top, creating noise. This indicator categorizes patterns into five distinct levels of strength, ranging from simple indecision to very strong reversal or continuation signals.
Furthermore, it incorporates a Trend Context filter, which checks the relationship between price and a Simple Moving Average (SMA). This ensures that reversal patterns (like Hammers) are prioritized during downtrends, while continuation patterns are highlighted during established moves, reducing false positives.
● Methodology
The indicator evaluates price action using specific ratios between the Open, High, Low, and Close, alongside the body size relative to the total range. It assigns a strength score to each detected pattern.
• Pattern Strength Grading
Strength 1 (Indecision): Includes patterns like Doji, Spinning Tops, Dragonfly, and Gravestone Dojis. These signal a pause in momentum.
Strength 2 (Weak): Includes patterns like Hanging Man, Inverted Hammer, Belt Holds, and In-Neck lines. These suggest potential movement but often require confirmation.
Strength 3 (Moderate): Includes classic reversals like Hammers, Shooting Stars, Haramis, Dark Cloud Cover, and Piercing Lines.
Strength 4 (Strong): Includes major signals like Engulfing patterns, Morning/Evening Stars, and Marubozu candles.
Strength 5 (Very Strong): Reserved for rare, high-probability multi-candle formations like Three White Soldiers, Three Black Crows, Rising/Falling Three Methods, and Breakaway gaps.
The script calculates all potential patterns for the current bar and then compares their strength scores. Only the pattern with the highest strength is displayed. If the Show Trend Context option is enabled, the script further validates the pattern against the current market direction (determined by the SMA and slope) before plotting.
● How to Use
Traders can use this tool to identify potential entry and exit points based on the strength of the signal.
• Visual Signals
Patterns are labeled directly on the chart:
Green Labels/Text: Indicate Bullish patterns.
Red Labels/Text: Indicate Bearish patterns.
Gray/White Labels: Indicate Indecision or Weak patterns.
Hovering over any label provides the full name of the pattern and its strength rating (e.g., "Bullish Engulfing - Strength: Strong").
• Trading Logic
High Strength Signals (Levels 4-5): These can be used as primary triggers for trend reversals or strong continuations.
Moderate Signals (Level 3): Useful for adding confluence to existing analysis or anticipating a setup.
Indecision (Level 1): Often useful for taking profits or tightening stop-losses, as they indicate the current trend may be stalling.
● Settings
Show Only Strong Patterns: When enabled, filters out Strength 1, 2, and 3, showing only the most significant signals (Strength >= 4).
Max Patterns to Display: Limits the number of historical labels to prevent chart clutter.
Max Candles to Check Engulfing: Adjusts how far back the script looks to validate the size of an engulfing candle.
Trend Detection Period: Sets the length of the SMA used to determine the background trend context.
Show Only Trend-Appropriate Patterns: If checked, bullish reversals are only shown in downtrends, and bearish reversals in uptrends.
● Disclaimer
All provided scripts and indicators are strictly for educational exploration and must not be interpreted as financial advice or a recommendation to execute trades. I expressly disclaim all liability for any financial losses or damages that may result, directly or indirectly, from the reliance on or application of these tools. Market participation carries inherent risk where past performance never guarantees future returns, leaving all investment decisions and due diligence solely at your own discretion.
Candlestick-pattern
Vanilla ABCD PatternPatterns makes parts of the many predictive tools available to technical analysts, the most simples ones can be easily detected by using scripts. The proposed tool detect the simple (vanilla) form of the ABCD pattern, a pattern aiming to detect potential price swings. The script can use an additional confirmation condition that aim to filter potential false signals.
ABCD PATTERN
The ABCD pattern is not meant to be detected by analyzing individuals closing price observations but by analyzing longer term movements, this is done by using tools such as zig-zag. Like any pattern the ABCD one comes in different flavors, the simplest being based on the following structures:
Once price reach D we can expect a reversal. The classical pattern has the following conditions : BC = 0.618*AB and CD = 1.618*AB , as you can see this condition is based on 0.618 which is a ratio in the Fibonacci sequence. Other conditions are for AB to equal to CD or for CD to be 161.8% longer than AB. Why these conditions ? Cause Fibonacci of course .
The ABCD pattern that the proposed tool aim to detect is not based on the zig-zag but only on individual price observations and don't make use of any of the previously described conditions, thus becoming more like a candle pattern.
When the label is blue it means that the tool has detected a bullish ABCD pattern, while a red label means that the tool has detected a bearish ABCD pattern.
We can't expect patterns based on the analysis of 1,2,3 or 4 closing price observations to predict the reversal of mid/long term movements, this can be seen on the above chart, but we can see some signals predicting short term movements.
Since the pattern is based on a noisy variation, using smoother input can result in less signals.
Above the tool on BTCUSD using closing price as input. Below the tool using ohlc4 as input:
TOOL OPTIONS
Being to early can be as devastating as being to late, therefore a confirmation point can be beneficial, the tool allow you to wait for confirmation thus having a potentially better timing. Below is a chart of AMD with no confirmation:
As we can see there are many signals with some of them occurring to early, we can fix this by checking the confirmation option:
The confirmation is simply based on the candle color, for example if a bearish ABCD pattern has been detected in the past and the closing price is greater than the opening price then the tool return a buy signal. The same apply with a bearish ABCD pattern.
The "last bar repaint" option is true by default, this in order to show the bar where the D point of the pattern has been detected, since the closing price of the last bar is constantly changing the signals on the last bar can be constantly appearing/disappearing, unchecking the option will fix this but will no longer the bar where the D point of the pattern has been detected.
SUMMARY
The pattern is simple and can sometimes be accurate when predicting the direction of future short terms movements. The tool was a request, as it seems i don't post many pattern detectors, well thats true, and the reason is that for me patterns are not super significant, and their detection can be extremely subjective, this is why simple patterns are certainly the only ones worth a look.
Don't expect me to post many pattern related indicators in the future ^^'
Bullish/Bearish Candelstick patternHey!
This time I took the pattern recognizer from a previous script I worked.
It overlays the Arrows on the chart.
Legend:
#Maroon colour: Strong bearish signal
#Red colour: Bearish signal
#Dark Green colour: Strong bullish signal
#Lime: Bullish signal
NOTE: Also, you can untick the patterns you don't find useful, but I kept every pattern to get a complete script.
I unticked:
Morning Star
Evening Star
Shooting Star
Bullish Harami (too bearish on corrective phase)
Hanging Man
Red Cloud Cover


