ATAI Volume Pressure Analyzer V 1.0 — Pure Up/DownATAI Volume Pressure Analyzer V 1.0 — Pure Up/Down
Overview
Volume is a foundational tool for understanding the supply–demand balance. Classic charts show only total volume and don’t tell us what portion came from buying (Up) versus selling (Down). The ATAI Volume Pressure Analyzer fills that gap. Built on Pine Script v6, it scans a lower timeframe to estimate Up/Down volume for each host‑timeframe candle, and presents “volume pressure” in a compact HUD table that’s comparable across symbols and timeframes.
1) Architecture & Global Settings
Global Period (P, bars)
A single global input P defines the computation window. All measures—host‑TF volume moving averages and the half‑window segment sums—use this length. Default: 55.
Timeframe Handling
The core of the indicator is estimating Up/Down volume using lower‑timeframe data. You can set a custom lower timeframe, or rely on auto‑selection:
◉ Second charts → 1S
◉ Intraday → 1 minute
◉ Daily → 5 minutes
◉ Otherwise → 60 minutes
Lower TFs give more precise estimates but shorter history; higher TFs approximate buy/sell splits but provide longer history. As a rule of thumb, scan thin symbols at 5–15m, and liquid symbols at 1m.
2) Up/Down Volume & Derived Series
The script uses TradingView’s library function tvta.requestUpAndDownVolume(lowerTf) to obtain three values:
◉ Up volume (buyers)
◉ Down volume (sellers)
◉ Delta (Up − Down)
From these we define:
◉ TF_buy = |Up volume|
◉ TF_sell = |Down volume|
◉ TF_tot = TF_buy + TF_sell
◉ TF_delta = TF_buy − TF_sell
A positive TF_delta indicates buyer dominance; a negative value indicates selling pressure. To smooth noise, simple moving averages of TF_buy and TF_sell are computed over P and used as baselines.
3) Key Performance Indicators (KPIs)
Half‑window segmentation
To track momentum shifts, the P‑bar window is split in half:
◉ C→B: the older half
◉ B→A: the newer half (toward the current bar)
For each half, the script sums buy, sell, and delta. Comparing the two halves reveals strengthening/weakening pressure. Example: if AtoB_delta < CtoB_delta, recent buying pressure has faded.
[ 4) HUD (Table) Display /i]
Colors & Appearance
Two main color inputs define the theme: a primary color and a negative color (used when Δ is negative). The panel background uses a translucent version of the primary color; borders use the solid primary color. Text defaults to the primary color and flips to the negative color when a block’s Δ is negative.
Layout
The HUD is a 4×5 table updated on the last bar of each candle:
◉ Row 1 (Meta): indicator name, P length, lower TF, host TF
◉ Row 2 (Host TF): current ↑Buy, ↓Sell, ΔDelta; plus Σ total and SMA(↑/↓)
◉ Row 3 (Segments): C→B and B→A blocks with ↑/↓/Δ
◉ Rows 4–5: reserved for advanced modules (Wings, α/β, OB/OS, Top
5) Advanced Modules
5.1 Wings
“Wings” visualize volume‑driven movement over C→B (left wing) and B→A (right wing) with top/bottom lines and a filled band. Slopes are ATR‑per‑bar normalized for cross‑symbol/TF comparability and converted to angles (degrees). Coloring mirrors HUD sign logic with a near‑zero threshold (default ~3°):
◉ Both lines rising → blue (bullish)
◉ Both falling → red (bearish)
◉ Mixed/near‑zero → gray
Left wing reflects the origin of the recent move; right wing reflects the current state.
5.2 α / β at Point B
We compute the oriented angle between the two wings at the midpoint B:
β is the bottom‑arc angle; α = 360° − β is the top‑arc angle.
◉ Large α (>180°) or small β (<180°) flags meaningful imbalance.
◉ Intuition: large α suggests potential selling pressure; small β implies fragile support. HUD cells highlight these conditions.
5.3 OB/OS Spike
OverBought/OverSold (OB/OS) labels appear when directional volume spikes align with a 7‑oscillator vote (RSI, Stoch, %R, CCI, MFI, DeMarker, StochRSI).
◉ OB label (red): unusually high sell volume + enough OB votes
◉ OS label (teal): unusually high buy volume + enough OS votes
Minimum votes and sync window are user‑configurable; dotted connectors can link labels to the candle wick.
5.4 Top3 Volume Peaks
Within the P window the script ranks the top three BUY peaks (B1–B3) and top three SELL peaks (S1–S3).
◉ B1 and S1 are drawn as horizontal resistance (at B1 High) and support (at S1 Low) zones with adjustable thickness (ticks/percent/ATR).
◉ The HUD dedicates six cells to show ↑/↓/Δ for each rank, and prints the exact High (B1) and Low (S1) inline in their cells.
6) Reading the HUD — A Quick Checklist
◉ Meta: Confirm P and both timeframes (host & lower).
◉ Host TF block: Compare current ↑/↓/Δ against their SMAs.
◉ Segments: Contrast C→B vs B→A deltas to gauge momentum change.
◉ Wings: Right‑wing color/angle = now; left wing = recent origin.
◉ α / β: Look for α > 180° or β < 180° as imbalance cues.
◉ OB/OS: Note labels, color (red/teal), and the vote count.
◉Top3: Keep B1 (resistance) and S1 (support) on your radar.
Use these together to sketch scenarios and invalidation levels; never rely on a single signal in isolation.
[ 7) Example Highlights (What the table conveys) /i]
◉ Row 1 shows the indicator name, the analysis length P (default 55), and both TFs used for computation and display.
◉ B1 / S1 blocks summarize each side’s peak within the window, with Δ indicating buyer/seller dominance at that peak and inline price (B1 High / S1 Low) for actionable levels.
◉ Angle cells for each wing report the top/bottom line angles vs. the horizontal, reflecting the directional posture.
◉ Ranks B2/B3 and S2/S3 extend context beyond the top peak on each side.
◉ α / β cells quantify the orientation gap at B; changes reflect shifting buyer/seller influence on trend strength.
Together these visuals often reveal whether the “wings” resemble a strong, upward‑tilted arm supported by buyer volume—but always corroborate with your broader toolkit
8) Practical Tips & Tuning
◉ Choose P by market structure. For daily charts, 34–89 bars often works well.
◉ Lower TF choice: Thin symbols → 5–15m; liquid symbols → 1m.
◉ Near‑zero angle: In noisy markets, consider 5–7° instead of 3°.
◉ OB/OS votes: Daily charts often work with 3–4 votes; lower TFs may prefer 4–5.
◉ Zone thickness: Tie B1/S1 zone thickness to ATR so it scales with volatility.
◉ Colors: Feel free to theme the primary/negative colors; keep Δ<0 mapped to the negative color for readability.
Combine with price action: Use this indicator alongside structure, trendlines, and other tools for stronger decisions.
Technical Notes
Pine Script v6.
◉ Up/Down split via TradingView/ta library call requestUpAndDownVolume(lowerTf).
◉ HUD‑first design; drawings for Wings/αβ/OBOS/Top3 align with the same sign/threshold logic used in the table.
Disclaimer: This indicator is provided solely for educational and analytical purposes. It does not constitute financial advice, nor is it a recommendation to buy or sell any security. Always conduct your own research and use multiple tools before making trading decisions.
Oversold-oscillators
RSI Multi TF strategy
The RSI is a very popular indicator that follows price activity.
It calculates an average of the positive net changes, and an average
of the negative net changes in the most recent bars, and it determines
the ratio between these averages. The result is expressed as a number
between 0 and 100. Commonly it is said that if the RSI has a low value,
for example, 30 or under, the symbol is oversold. And if the RSI has a
high value, 70 for example, the symbol is overbought.
Plots 3 RSI (Weekly, Daily, 4h) at the same time, regardless of the Chart Timeframe.
Highlights in green (or red) if all RSI is oversold (or overbought).
Can trigger custom oversold and overbought alerts when all 3 lines grey(4h), yellow(weekly), and red(daily) go in the oversold or overbought zone. The strongest the curves break the barrier the strongest the alert (vertical red and green bars) shows.
Colored Williams %RThis script is the same as Williams %R except that on green days we plot green and red on red days. If a bar opens and closes the same, we plot black.