Two-Touch Liquidity Levels [tradewsamet]

1 339
💧 Two-Touch Liquidity Levels marks buy-side (BSL) and sell-side (SSL) liquidity pools only after a level has been defended on two separate occasions. A swing high or low on its own is treated as a level, not a pool. It becomes a pool when price leaves it, travels a minimum distance away, comes back and is rejected there again. Each pool shows every touch, how it was built and how far price is from it in ATR, and when price takes a pool the script records whether it was swept back or broken.

Most equal highs and equal lows tools connect any two swing points that print at a similar price. Two swings a few candles apart, inside the same small pullback, are usually one decision by the market, not two. Those tools also leave a line on the chart for every match, so the chart fills up and fresh levels are hard to tell from stale ones. This script answers a narrower question: has this level been defended on two independent occasions, how close is price to it now, and when price reached pools like it on this chart, did they hold or give way?

The core idea: one touch is a level, two is a pool. Fewer lines, each one earned.

📊 OVERVIEW

Every level moves through the same states:

— Level: a confirmed swing high or low becomes the first touch. It is shown as a faint dotted line with a progress tag: ●○ means one of two touches
— Pool Formed: price returns to the level after an independent departure and closes back on the near side of it. The level turns into a glowing pool
— Pool Approached: a bar closes within the approach distance of the pool. The pool lights up (white on dark charts) and the approach alert fires
— Pool Taken: price trades beyond the touch band. The close of that bar marks it SWEPT (closed back inside) or BROKEN (accepted beyond)

Levels that never earn a second touch are forgotten after the Second Touch Window. Pools that are never taken are retired after the Max Pool Age.

🧩 WHY THESE COMPONENTS WORK TOGETHER

The touch rule, the drawing, the approach state, the outcome and the dashboard all read from the same store of levels, so they cannot contradict each other. The pool that lights up on approach is the same pool whose touches are marked on the chart, and the outcome written on it when it is taken feeds the swept-back counts on the dashboard directly.

The chain is:
Swing level → Independent second touch → Pool → Approach → Take → Swept or broken → Dashboard counts

🔍 WHAT MAKES THIS MODEL ORIGINAL

1️⃣ An independent touch rule

A touch only counts if three conditions are met since the previous touch: price moved away from the level by at least the Departure distance (default 1.5 ATR), at least the minimum number of bars has passed (default 5), and the touching bar closed back on the near side of the level. Candles grinding along a level count as one touch, not many.

2️⃣ A touch band fixed at birth

The tolerance around the first touch (default 0.15 ATR) is fixed when the level is born. It does not widen or narrow as volatility changes later, so a pool cannot drift toward price over time.

3️⃣ A drawing that shows how the pool was built

The glow on the side where resting orders sit steps up with every touch: faint while the level has a single touch, full once it becomes a pool, taller and brighter with a third and fourth touch. A soft arc bridges each pair of touches, and a glowing dot marks every touch on the candle that made it. The history of a pool can be read from the chart without opening a tooltip.

4️⃣ A swept or broken outcome, counted per side

When a pool is taken, the script reads the close of the same bar. A close back inside the band marks it SWEPT. A close beyond the band marks it BROKEN. The dashboard keeps the swept-back share for buy-side pools, for sell-side pools and for all pools on the chart, plus the outcome of the last six.

5️⃣ Depth instead of clutter

Only the nearest pools above and below price are drawn (default three per side). The nearest pool on each side is drawn strongest with a solid tag, and the pools behind it fade back with tinted tags. Other pools stay in memory and appear as price moves closer.

6️⃣ Distance in ATR everywhere

The distance to every pool is measured in ATR, on the chart ruler and on the dashboard, so a reading means the same thing on gold, indices, crypto and forex.

🧠 HOW IT WORKS — CALCULATION FLOW

Step 1 — Levels: a swing high or low with Swing Strength bars on each side (default 5) is confirmed that many bars after it prints. It becomes the first touch, unless an existing level on the same side already covers that price.

Step 2 — Departure: the script tracks how far price has moved away from the level since the last touch. Once the distance reaches the Departure setting and enough bars have passed, the level is ready for its next touch.

Step 3 — Touch: a bar whose high (BSL) or low (SSL) reaches the touch band and that closes back on the near side of the level adds one touch. When the count reaches Touches To Form A Pool (default 2), the level becomes a pool. The pool is drawn at its most extreme touch: the highest touch for BSL, the lowest for SSL.

Step 4 — Approach: when a bar closes within the Approach Distance (default 0.75 ATR) of a pool, the pool lights up and the approach alert fires once. It rearms after price moves away by twice that distance.

Step 5 — Take: a high above the top of the band (BSL) or a low below the bottom of the band (SSL) takes the pool. The close of that bar decides SWEPT or BROKEN, and the counts on the dashboard update.

📖 HOW TO USE

🎯 Quick start:

1. Add the indicator to a chart between 15 minutes and 4 hours.
2. Read the status line at the top of the dashboard. It tells you whether price is at a pool, which side is closer, or which pool was just taken.
3. Check the two cards: the nearest buy-side and sell-side pool with price, distance in ATR, touches, proximity and age.
4. Treat a lit pool as a level price is testing now, and watch how the bar that takes it closes.
5. Check the swept-back share for that side before relying on either reading on this symbol.
6. Raise Touches To Form A Pool to 3 to keep only the most defended levels.

👁️ Reading the chart:

— BSL pools above price in cyan, SSL pools below price in amber. Both colors stay clear of red and green candles
— The glow sits on the side where resting orders are: above BSL, below SSL
— Tags show the side and one dot per touch, for example BSL ●●
— Dotted lines with ●○ are levels waiting for their next touch
— A dotted ruler just right of the last bar shows the distance to the nearest pool on each side in ATR
— A lit pool and tag: price is at the pool
— SWEPT and BROKEN marks sit on the wick that took the pool, with that part of the wick lit up
— Hover any tag, dot or mark for price, touches, age and distance

📋 Dashboard:

— Status line: AT BUY-SIDE LIQUIDITY, CLOSER TO SELL-SIDE, BSL JUST SWEPT and similar states
— Buy-side and sell-side cards: pool price, distance in ATR, touch dots, a proximity meter, the pool age and that side's swept-back share. When price is at the pool, the distance row fills with the pool color
— When a side has no pool yet, its card shows the nearest level waiting for its next touch, dimmed
— Swept back: the share of all taken pools on the chart that closed back inside, with a meter
— Last 6 taken: ● swept back, ○ broken, oldest on the left
— The latest event and how long ago it happened

The proximity meter is full at the level and empty when price is 10 ATR or more away.

🎨 VISUALS

The theme follows the chart background automatically or can be set to Dark or Light, with optional custom BSL and SSL colors. The glow, touch dots, touch arcs, depth fade and distance ruler can each be turned off. The label size has four steps, and the age and price can be added to each tag. Taken pools can be kept on the chart for review (up to 40). Reels Mode enlarges the tags and the dashboard for vertical recordings. The dashboard can be placed in six positions with three text sizes, and the statistics cards can be hidden for a smaller panel.

⚙️ KEY SETTINGS

💧 Pool Rules:

— Swing Strength: default 5
— Touches To Form A Pool: default 2
— Touch Tolerance: default 0.15 ATR
— Departure Between Touches: default 1.5 ATR
— Min Bars Between Touches: default 5
— Second Touch Window: default 300 bars
— Max Pool Age: default 1500 bars
— Approach Distance: default 0.75 ATR

🎨 Visuals:

— Pools Per Side: default 3
— Waiting Levels Per Side: default 2
— Theme, Label Size, Liquidity Glow, Touch Dots, Touch Arcs, Depth Fade, Distance Ruler, Age In Tag, Price In Tag, Show Taken Pools, Taken Pools To Keep, custom colors, Reels Mode

📊 Dashboard:

— Show Dashboard, Statistics Cards, Position, Text Size

🔔 ALERTS

— Two-Touch: Pool Formed: a level earned its second independent touch
— Two-Touch: Pool Approached: price closed near a pool
— Two-Touch: Pool Taken: a pool was taken
— With Send Event Alerts on, one alert set to "Any alert() function call" sends every event as a JSON message with the event, side, symbol, timeframe, level, touch count and outcome (swept or broken)

Alerts describe a change in the script's state. They are not trade instructions.

⚠️ IMPORTANT NOTES & LIMITATIONS

— ✅ Touches, approaches and takes are confirmed on bar close. On the forming bar the drawing follows price live and can change until the bar closes. The JSON alerts fire once per bar close.
— ⏱️ The first touch of every level is a swing point, confirmed Swing Strength bars after it prints. The pool itself appears on the bar of the second touch.
— 📐 Touches and takes are checked with the bar's high and low. A bar that closes beyond the level is not counted as a touch.
— 🔁 Pools are measured on the chart's own timeframe. The same symbol on another timeframe gives different pools.
— 📊 The swept-back shares count behavior on the history loaded on the chart. Different timeframes and history lengths give different counts. They describe past pools, not the next one.
— 🗂️ Up to 150 levels are kept in memory. Only the nearest pools and waiting levels are drawn.
— 🛠️ Looser settings produce more pools. More pools do not make any single pool more likely to hold.

🛡️ DISCLAIMER

This script is provided for educational and analytical purposes. It does not provide financial advice or guarantee any trading outcome.
The pools, touch counts, outcomes, dashboard values and alerts describe the script's internal rules only. They should be checked against your own analysis and risk tolerance before any decision is made.

免責事項

これらの情報および投稿は、TradingViewが提供または承認する金融、投資、取引、またはその他の種類の助言もしくは推奨であることを意図したものではなく、またこれらに該当するものでもありません。詳細は利用規約をご覧ください。