HVN Fade & Break | Volume Profile Fade & Breakout Strategy

5 021
This strategy builds a rolling multi-session volume profile directly on the chart and trades two distinct setups off it.

Every time a new session begins (daily or weekly, your choice), the script closes out the prior session's histogram, tags its Point of Control as a fresh "naked" POC, and rebuilds the profile using the last N closed sessions. From that histogram it derives the session's Point of Control (POC), Value Area High/Low (VAH/VAL) via a standard two-sided volume expansion, and a set of High Volume Node (HVN) zones found through local-maximum and prominence-based peak detection — the same family of techniques used in dedicated volume-profile and Market Profile tools, reimplemented here as one self-contained strategy.

Two setups fire off this structure:
  • Fade — price pokes outside the value area and closes back inside on the same bar, with RSI confirming the reversal is overbought/oversold. Target: the session POC.
  • Breakout — price closes cleanly through VAH/VAL on volume above its recent average. Target: the nearest HVN zone or untouched (naked) POC beyond price, falling back to a fixed R-multiple if neither exists.
  • Stops combine an ATR-based distance with the nearest confirmed swing pivot, so both setups have a structural backstop rather than a purely volatility-based one.


Features
  • Rolling N-session volume profile (POC / VAH / VAL) rebuilt automatically at each new session
  • HVN zone detection with adjustable peak threshold, peak window, minimum prominence, and zone width
  • Naked POC tracking — untouched prior-session POCs extend right until price trades back through them, and can be used as breakout targets
  • Two independent, toggleable setups: mean-reversion fade and volume-confirmed breakout (run either or both)
  • Swing-pivot + ATR hybrid stop placement
  • Optional single-position-at-a-time restriction
  • Full visual layer: value area shading, POC line, HVN zone boxes, naked POC lines, and long/short signal markers
  • Built-in commission and slippage modeling for realistic backtests


Tips
  • Keep the profile period on "D" and trade a chart timeframe clearly below it (5m–15m works well) — the profile needs enough bars per session to build a meaningful histogram.
  • Test fade-only and breakout-only separately before running both together; they behave very differently across trending vs. range-bound conditions.
  • lookbackPeriods around 10–20 sessions is a reasonable starting range — shorter reacts faster, longer smooths out noise.
  • Run this on liquid instruments with genuine centralized volume (index futures, large-cap equities, major ETFs). Thin names or tick-volume proxies (e.g. spot forex) will produce an unstable, unreliable profile.
  • Walk this forward across several symbols and time windows before trusting any single backtest — with this many tunable inputs, overfitting to one chart is an easy trap.


Warnings
  • This is an educational template, not a finished or optimized trading system. Defaults are illustrative starting points, not tuned recommendations for any specific instrument.
  • Position sizing here is percent-of-equity, not risk-normalized — trades with wider stops risk proportionally more capital than trades with tighter stops. Understand this before sizing up.
  • There is no minimum reward:risk filter or drawdown circuit breaker built in; the strategy will take every qualifying signal regardless of how favorable (or unfavorable) the resulting stop/target geometry is.
  • Past performance in backtest, including on the sample chart, does not guarantee future results. This is not financial advice — verify behavior thoroughly in a simulated environment before considering live use.

Penafian

Maklumat dan penerbitan adalah tidak bertujuan, dan tidak membentuk, nasihat atau cadangan kewangan, pelaburan, dagangan atau jenis lain yang diberikan atau disahkan oleh TradingView. Baca lebih dalam Terma Penggunaan.