Liquidity Heatmap, Liquidation Levels & Clusters [LunqFX]

3 805
Liquidity Heatmap maps where leveraged traders would be liquidated. Every bar is treated as a place where longs and shorts were opened; for each leverage tier the script projects their liquidation levels, removes every level price has already traded through, and paints what is left as a heatmap. The brighter the band, the more untouched liquidation fuel is stacked at that price. A side profile ranks the bands, and the biggest cluster above and below price is labelled with its distance.

Liquidation heatmaps are usually built for crypto with a fixed leverage, which on forex or gold puts every level far off the chart. This one has an Auto mode that sets the liquidation distance from each bar's own volatility (ATR), so the map sits around price on any market and timeframe — crypto, forex, gold or indices — while the classic leverage mode is still there for crypto. It also keeps only the levels that have not been hit yet, and reads the balance of fuel above and below price in the panel. It does not use swing points or liquidity pools: the map comes entirely from the modelled positions.

❶ HOW THE MAP IS BUILT ① Positions — on every bar of the history window, longs and shorts are assumed to open at the close. ② Liquidation levels — for each tier, a long is liquidated a set distance below the close and a short the same distance above it. ▸ Auto (volatility): the three tiers sit 2, 4 and 8 ATR from the close. ▸ Manual leverage: the classic 1 / leverage from the close (25× = 4%, 50× = 2%, 100× = 1%). ③ Weight — each bar's levels are weighted by its volume, its range, or equally. ④ Liquidated levels are removed — a level is kept only if no later bar has traded through it. What remains is fuel that has not been taken yet. ⑤ Heat — the remaining levels are summed into price rows. The hottest row is 100%, everything else is scaled to it.

❷ WHAT YOU SEE ▸ Heat bands — every live level is a line from the bar that created it to the current bar, coloured from cold violet through pink and orange to white-hot yellow ▸ Side profile — one bar per price row to the right of price; the longer and brighter, the more fuel ▸ ▲ SHORT LIQ CLUSTER — the biggest band above price (where shorts would be liquidated), with its distance in % ▸ ▼ LONG LIQ CLUSTER — the biggest band below price (where longs would be liquidated), with its distance in %

❸ THE PANEL ▸ Live levels on the map ▸ Fuel above · below — the share of all remaining fuel on each side, with a bar ▸ Biggest cluster above and below, with distance in % ▸ Nearer of the two ▸ The distance mode and tiers in use, and the weighting ▸ A heat scale and the note that this is a model built from price

❹ HOW TO USE IT

Read the two labelled clusters. Large untouched clusters are prices the market has not visited since those positions were opened; traders watch them as potential targets because of the stops and liquidations that would rest there.
Read the fuel balance: when most of the fuel is on one side, that side holds more resting liquidity.
Watch a cluster disappear when price trades through it — the map updates on every bar.
Use it as context for your own entries and risk; it is not a signal.
Works on crypto, forex, gold (XAUUSD), indices and stocks. For crypto try Manual leverage 25 / 50 / 100×; for everything else keep Auto.
❺ SETTINGS Leverage ▸ Liquidation distance: Auto (volatility) or Manual leverage — Auto is the default and works on every market ▸ Auto tiers (× ATR) — 2 / 4 / 8 by default ▸ Bars of history — how far back positions are modelled ▸ Tier 1 / 2 / 3 on or off, and their leverage (Manual mode) ▸ Weight each bar by — Volume, Range (for symbols without volume) or Equal Heatmap ▸ Price rows — how finely the price axis is split ▸ Hide bands cooler than (%) · Max levels drawn ▸ Side profile and its width · Label the biggest cluster above and below ▸ Show levels within (× ATR of price) — keeps distant levels off the map so the candles stay readable Panel ▸ Show panel · position · text size Alerts ▸ Alert when a top cluster is within (%) of price Visuals ▸ Neon candles — graphite and white, so the heat is what stands out. Off = your own chart candles. ▸ Glow candles — each body brightens towards the close. Off = flat bodies.

❻ ALERTS ▸ Price within the set % of the biggest short-liquidation cluster above ▸ Price within the set % of the biggest long-liquidation cluster below Create the alert with "Any alert() function call". Messages are sent on bar close.

❼ HOW IT UPDATES The map is a picture of the current moment: it is rebuilt on the last bar from the bars in the history window, and levels disappear as price trades through them. It is not a historical signal, so earlier states of the map are not kept on the chart. Every level comes from closed bars; the script does not use request.security or lookahead.

LIMITATIONS ▸ This is a model built from price (and optionally volume), not exchange liquidation or order-book data. Real positions, leverage and stop placement are unknown, and the map shows where they would sit under the model's assumptions. ▸ Auto mode places levels by volatility rather than by a real exchange leverage; it is a practical scale for markets where leverage is not one fixed number. ▸ Only the bars in the history window are modelled, and only levels within the chosen ATR window are drawn; liquidity further away is not shown. ▸ TradingView limits the number of lines on a chart, so only the heaviest levels are drawn; the profile and the clusters use all of them. ▸ Volume weighting depends on the volume your data feed reports; for forex it is tick volume. Use Range or Equal where volume is not meaningful. ▸ A cluster is a place where liquidity rests, not a promise that price will go there.

This script is for educational purposes only and is not financial advice. Trading involves risk.

Aviso legal

As informações e publicações não se destinam a ser, e não constituem, conselhos ou recomendações financeiras, de investimento, comerciais ou de outro tipo fornecidos ou endossados pela TradingView. Leia mais nos Termos de Uso.