Candle DNA Morphology | AnonycryptousCandle DNA Morphology | Anonycryptous
Description & user manual
Why is this indicator different:
Most candle analysis tools work with names. They look at a candle and call it an engulfing, a hammer, a doji, a shooting star. They compare shape against a fixed template and fire a signal when the match is close enough. The problem is that names are approximations. A hammer in a trending market is not the same as a hammer at a structural level with elevated volume. A name cannot capture that. A fixed template cannot either.
Candle DNA Morphology works differently.
It does not use names. It does not use templates. It compares the current candle to every historical candle within a configurable lookback window and finds the one that is mathematically closest — across up to eight normalized dimensions simultaneously. Body size, wick proportions, body position within the range, relative volume, candle size relative to recent volatility, trend alignment, and structural context. Then it tells you what happened after that historical candle, directly on the chart, with a single marker you can hover.
Other tools that use candle similarity show you statistics. Continuation rates. Reversal percentages. Tables to read and interpret. You still have to decide what the numbers mean and whether they matter right now.
Candle DNA Morphology does not show you statistics. It shows you a signal — the exact historical candle that matched, marked on the chart, with the date, the score, the direction, the R value, the percentage move, and the price move of what followed. No table to interpret. No calculation required. The information is in the hover.
The score tells you how close the match was. The tier tells you how rare it is. The color tells you the direction. Everything else is in the tooltip.
Important notice
Candle DNA Morphology generates signals based on historical pattern similarity and price behavior.
These signals are not financial advice.
They do not predict the future.
They do not guarantee profitability.
The outcome values shown — R, percentage, and price — are historical measurements from the matched candle in the past. They reflect what happened then, on that instrument, at that price level. The market may behave differently now. Similar candles can produce different results. These values are context, not certainty.
All trading decisions are made entirely by the user.
Always manage your own risk. Always apply your own judgment.
1. Overview
Candle DNA Morphology is a candle fingerprint matching indicator built around the mathematical similarity between the current candle and historical ones — and what those historical candles preceded.
What it includes:
- Up to 8-dimensional candle fingerprint matching using Euclidean distance
- Configurable lookback window from 50 to 1000 bars
- Three signal quality tiers: standard, elite, and ultra
- Hoverable triangle markers on signal bars with full match details in the tooltip
- Diamond marker and vertical line on the exact historical matched candle
- Configurable cooldown between signals to prevent clustering
- Signal mode selector: current bar, match bar, or both
- Dynamic score normalization — score stays 0-100 regardless of how many dimensions are active
- Vertical signal line and background glow on qualifying bars
- Live dashboard with score bar, tier, bias, match date, outcome in R / percentage / price, cooldown countdown, active dimensions, and ATR
- All times displayed in the timezone you select in the dashboard settings
- Four alerts: bull match, bear match, elite match (90+), ultra match (95+)
2. How the fingerprint works
Every candle is described by a set of normalized values between 0 and 1. These values capture the shape and context of the candle without using price or time units — which is what makes the engine self-calibrating across instruments and timeframes.
The five core dimensions are always active:
Body ratio. The size of the body relative to the total candle range. A full-body candle scores near 1. A doji scores near 0.
Upper wick. The upper wick as a proportion of the total range. A long upper wick scores high. A candle with no upper wick scores 0.
Lower wick. Same logic for the lower wick.
Body position. Where the body sits within the range — 0 is at the bottom, 1 is at the top. A bullish candle with a close near the high scores near 1. A bearish candle with a close near the low scores near 0.
Relative volume. Volume divided by the 20-bar average, capped at 3x and normalized. A spike at 2x average scores higher than a quiet bar at 0.8x.
Three optional dimensions can be enabled independently:
Atr percentile (dimension 6). How large the current candle is relative to recent volatility. Measures the candle range against the 14-bar ATR, normalized to a 0-2x cap. A large candle matches better with historically large candles.
Trend alignment (dimension 7). How far the close sits above or below EMA 21, normalized to the ATR. A bullish candle well above the EMA matches better with historical bullish candles that were also above the EMA.
Candle context (dimension 8). The relationship between the current candle and the previous one. Inside bars score 0. Outside bars score 1. Normal bars score 0.5. This dimension helps the engine recognize structural setups like inside bar breakouts.
3. Scoring and tiers
Similarity is measured using Euclidean distance — the straight-line distance between two candles in multi-dimensional space. The closer two candles are in this space, the more similar they are.
The maximum possible distance scales automatically with the number of active dimensions, so the score always ranges from 0 to 100 regardless of configuration. A score of 100 would mean a perfect match across all active dimensions. A score of 70 means a strong structural similarity. A score of 95 or above is exceptionally rare.
Three tiers determine how signals are displayed:
Standard (70-89). Green for bull, red for bear. The match is meaningful but not uncommon.
Elite (90-94). Gold marker with a star prefix ★. The match is close enough to be notable. These appear infrequently.
Ultra (95+). Cyan marker with a diamond prefix ◈. A near-identical historical candle was found. Very rare. When one fires, it is worth attention.
4. Understanding the signal
When a signal fires, two things appear on the chart depending on your signal mode setting.
A triangle on the current bar points in the direction the market moved after the historical match — up for a bullish outcome, down for a bearish one. Hovering the triangle with your cursor or S-Pen shows the full match details: the date and time of the historical candle, the score, the tier, the bias, the outcome in R, and the R value.
When a signal fires, two dotted lines and a vertical connector appear on the chart. The first dotted line runs horizontally from the signal bar close — this is the entry reference level, the price from which all R, percentage, and dollar measurements are calculated. The second dotted line shows the target level — where the market would reach if the historical outcome repeats. A vertical connector at the end of the forward window closes the structure. All three lines run exactly as many bars as your forward outcome setting.
The target level is calculated using the current ATR, not the historical ATR from the matched candle. This makes it relevant to the current market conditions. Hovering the target line shows both values — the target using the current ATR and the target using the historical ATR — so you can see how much volatility has changed between then and now. If the current ATR is significantly higher than the historical ATR, the target is further away than it was in the original setup. If it is lower, the target is closer.
A diamond and a vertical line on the historical matched candle shows you exactly which bar was used as the reference. The line runs through the full range of that candle so there is no ambiguity about which bar matched. The color follows the signal tier.
In addition to the dotted lines, the indicator can draw historical projection candles to the right of the signal bar. This feature is off by default and can be enabled in the visuals settings. When enabled, candles appear to the right of the signal bar showing the exact OHLC of the bars that followed the historical matched candle. Each candle has a body and centered wicks, drawn in the tier color of the signal. They scale correctly with chart zoom. A small label above the first candle reads "Historical projection" to make it immediately clear that these are historical bars, not predictions. The number of projection candles follows your forward outcome setting. Body transparency and wick transparency are independently configurable in settings.
The bias shown in the dashboard and the tooltip is the direction the market moved after the matched candle — not a prediction of what will happen now. It is historical context, not a guarantee.
All times shown in this indicator use the timezone you select in the dashboard settings. The default is UTC. Set it to your local timezone — for example UTC+2 for Amsterdam, UTC-4 for New York, UTC+9 for Tokyo — and all match times will display in your local time automatically.
5. Understanding the outcome values
The dashboard and tooltip show three outcome measurements for the historical matched candle. All three describe the same move — the price action in the bars following that historical candle — expressed in different units.
Outcome (R). How far price moved after the matched candle, expressed as a multiple of the ATR at that historical bar. This is the primary measurement. It is instrument-independent and works the same on BTC, SOL, MNQ, or any other asset. A value of +2.4R means price moved 2.4 times the ATR upward in the forward window.
Outcome (%). The same move expressed as a percentage of the close price at the matched candle. This gives a more intuitive sense of the magnitude for traders who think in percentage terms.
Outcome (price). The same move expressed in the currency of the instrument. This is the raw price distance the market covered — for example, $1,075 on Bitcoin or $0.87 on SOL. This value is calculated using the ATR and close price at the historical match bar, not at the current price.
The target line on the chart uses the current ATR rather than the historical ATR. This is intentional — the current ATR reflects how the market is moving right now, making the projected target more relevant to your actual trade. The historical ATR is still shown in the target line tooltip for reference, so you can see whether volatility has expanded or contracted since the original setup occurred. A large difference between the two ATR values means the market is in a different volatility regime than it was at the time of the match.
An important note on the price value: this reflects the historical move at the time and price of the matched candle. If Bitcoin was at 60,000 when the match occurred and is now at 78,000, the same R move produces a larger dollar value today than it did then. The price outcome is historical context — it shows what that candle type led to in dollar terms at that moment, not what the current setup will produce now.
This is not your personal risk-to-reward ratio. The R value gives you the historical move size. Your stop loss placement determines your actual R:R.
6. Bias and cooldown
The bias shown in the dashboard reflects the outcome direction of the current best match. It shows bull when the matched historical candle was followed by an upward move, and bear when it was followed by a downward move.
Bias changes when a new bar closes and the engine finds a different best match with a different historical outcome direction, or when the cooldown expires and a new signal fires pointing in a new direction.
During cooldown, the dashboard shows — wait. The last match date and all three outcome values remain visible. No new signal fires until the cooldown bar count has elapsed. The cooldown countdown shows how many bars remain before the next signal is allowed, or ready when it can fire freely.
Cooldown prevents signal clusters from forming on consecutive bars where the same setup repeats. On faster timeframes with many morphologically similar candles, a cooldown of 15 bars or more is strongly recommended.
7. Self-calibration
All fingerprint dimensions are normalized to values between 0 and 1. Volume is measured relative to its own 20-bar average. Candle size is measured relative to the ATR. Trend alignment is measured in ATR units. There are no fixed price thresholds anywhere in the engine.
This means the indicator adapts automatically to different instruments and timeframes. A BTC candle and an MNQ candle with the same proportional shape, same relative volume, and same relationship to their respective EMAs will produce the same fingerprint score — even though one trades at 78,000 and the other at 20,000.
When switching instruments, only the min match score typically needs a small adjustment. SOL and other volatile assets produce more morphological variation, so a slightly lower score threshold (75-80) often works better. More structured instruments like futures perform well at 85-90.
8. Settings guide
8.1 Match engine
Lookback window (bars). How many historical bars to scan for fingerprint matches. Range: 50-1000. Recommended: 500 on 1m-5m charts, 1000 on 15m and above. A larger window finds better matches but takes longer on lower timeframes.
Min match score (0-100). The minimum similarity score required to fire a signal. 70-79 is standard, 80-89 is strong, 90-94 is elite, 95+ is ultra. Start at 85 and adjust from there.
Cooldown between signals (bars). Minimum bars between signals. On a 5m chart, 15 bars equals 75 minutes. On a 1H chart, 15 bars equals 15 hours. Lower values produce more signals. Higher values enforce a minimum spacing between setups.
Dimension 6 — Atr percentile. Adds candle size context relative to recent volatility. Recommended: on.
Dimension 7 — Trend alignment. Adds EMA 21 directional context. Recommended: on.
Dimension 8 — Candle context. Adds inside/outside bar structural context. Recommended: on.
8.2 Outcome filter
Forward outcome (bars). How many bars after the historical match are used to measure the resulting move. Match this to your typical trade duration. On a 5m chart with 6 bars, the engine looks at 30 minutes of forward price action to determine the outcome direction and magnitude.
Min outcome move (ATR x). The historical match only qualifies if the resulting move exceeded this ATR multiple within the forward window. Filters out matches where the historical candle led to no meaningful move. Recommended: 1.0-2.0.
8.3 Visuals
Signal mode. Current bar only shows only the triangle. Match bar only shows only the diamond and vertical line on the historical candle. Both shows both simultaneously.
Show score on marker. When on, the triangle displays the score as text. When off, the triangle is clean. Hover always shows the full details regardless.
Signal bar background. Subtle glow on the signal bar in the tier color.
Vertical signal line. A faint vertical box through the signal bar. Useful for identifying signal bars when zoomed out.
Timezone. Select your local timezone from the dropdown. All match times in the dashboard and tooltips display in this timezone. Default is UTC. Amsterdam = UTC+2, London = UTC+1 (summer) or UTC, New York = UTC-4 (summer), Tokyo = UTC+9.
8.4 Dashboard
Score bar — visual meter 0-100 in tier color.
Tier — standard, ★ elite (90+), or ◈ ultra (95+).
Bias — ▲ bull or ▼ bear, or — wait during cooldown.
Match date — date and time of the historical matched candle in your selected timezone.
Outcome (R) — price move after the match in ATR multiples with forward bar count.
Outcome (%) — same move as a percentage of the historical close price.
Outcome (price) — same move in currency units at the historical price level.
Lookback — current lookback window setting.
Min score — current minimum score setting.
Cooldown — bars remaining until next signal, or ready.
Dimensions — how many dimensions are active and which ones (ATR, EMA, CTX).
ATR (14) — current ATR value.
9. Recommended starting settings
For 1m-5m scalping:
Lookback 500, min score 85, cooldown 15 bars, forward outcome 3 bars, min outcome move 1.0.
For 15m-1H:
Lookback 1000, min score 88, cooldown 8 bars, forward outcome 6 bars, min outcome move 1.5.
For 4H and above:
Lookback 1000, min score 90, cooldown 5 bars, forward outcome 4 bars, min outcome move 2.0.
10. How to use
Load the indicator and set signal mode to both. This gives you the triangle on the current signal bar and the diamond with border box on the historical matched candle simultaneously.
When a signal fires, hover the triangle with your cursor or S-Pen. Read the match date (UTC), score, bias, and outcome values. Then locate the diamond on the chart — the bordered box marks exactly which candle was matched. Look at what followed it on the chart. That is your reference.
The three outcome values give you the same historical move in three different units. Use whichever is most natural for how you think about size. The R value is instrument-independent. The percentage gives quick context. The price value shows the raw historical distance.
Watch the cooldown counter in the dashboard. When it shows ready, the next qualifying signal will fire without restriction. When it shows a bar count, the engine is waiting before it can fire again.
If you see too many signals, raise the min match score or increase the cooldown. If you see too few, lower the min outcome move or reduce the min score.
Candle DNA Morphology works best as a confluence tool. It tells you what the current candle morphology historically preceded. Your other indicators — levels, sessions, volume, trend — confirm whether the context justifies acting on it.
11. Disclaimer
This indicator is provided for educational and informational purposes only. Nothing in this document constitutes financial advice or any form of recommendation. Trading financial instruments involves substantial risk of loss. Past performance is not indicative of future results. You may lose all of your invested capital.
Anonycryptous accepts no responsibility or liability for any losses incurred as a result of using this indicator.
Pine Script® indicator






















