Обновлено
ZenAlgo - Channel

Получите этот и другие эксклюзивные индикаторы здесь — ZenAlgo Platinum
Этот индикатор опубликован в разделе платного контента ZenAlgo_Official. Оформите подписку за $249.00 в месяц и загружайте на свой график этот и другие эксклюзивные индикаторы от автора. Оплата производится на TradingView, доступ предоставляется сразу.
Перейти к ZenAlgo PlatinumOverview and required chart interaction
This indicator draws a price channel and a volume profile that are both anchored to a user defined swing range. To initialize it, the user must pick two chart timestamps using the script inputs:
After both points are set, the script analyzes the bars between Start and End, fits a sloped channel through that range, builds a volume profile aligned with the channel, and then projects all derived levels forward along the same slope.
Inputs and what they control
Volume area and profile resolution
Style and visibility
Deviation levels
Slope analysis and alerts
How the channel baseline is constructed from Start to End
Once Start is reached, the script begins accumulating bar-by-bar statistics until End is reached:
Why this works (within the chosen range):
How the channel height is determined and why the borders sit where they do
After computing the baseline slope, the script scans through the selected bars to measure how far price deviated above and below that baseline:
Why this works (and what it implies):
How the volume profile is built inside the channel
The script constructs a volume profile that is aligned with the sloped channel, not a flat horizontal range:
Why this works (and what it measures):
LOC, VAH, and VAL derivation
LOC (line of control)
Interpretation:
VAH and VAL
Interpretation:
Deviation bands around LOC
After LOC is known, the script creates additional parallel bands:
Interpretation:
Optional projections: Extend right and Ghost Extend
Two projection mechanisms exist:
Interpretation:
Pivot labels: HH, HL, LH, LL
The script optionally labels local swing points using pivot detection:
Interpretation:
Breakout detection on channel borders
Once End is set, the channel is considered active and the script evaluates each new bar against the channel borders at that bar index:
Interpretation:
Alerts included by the script
How to interpret the plotted elements together
A practical way to read the indicator is to separate it into three layers of information:
Channel structure
Activity structure inside the channel
Event markers
How to best use this indicator
Selecting Start and End effectively
Using LOC, VAH, and VAL for context
Using breakouts
Combining with pivot labels
Added value over other free indicators
Disclaimers and where the indicator can fall short
This indicator draws a price channel and a volume profile that are both anchored to a user defined swing range. To initialize it, the user must pick two chart timestamps using the script inputs:
- Start - the first anchor point (typically one extreme of the move, such as the swing low for an ascending move or the swing high for a descending move).
- End - the second anchor point (the opposite extreme of that same move).
After both points are set, the script analyzes the bars between Start and End, fits a sloped channel through that range, builds a volume profile aligned with the channel, and then projects all derived levels forward along the same slope.
Inputs and what they control
Volume area and profile resolution
- Width % controls how far the volume profile histogram can extend horizontally. It scales the longest profile bar relative to the Start-End range length.
- Volume Area % controls how much of total volume around the profile’s highest volume region is included when computing the value area boundaries.
Style and visibility
- Toggles exist for displaying the profile derived levels: LOC, VAH/VAL, pivot labels (HH, HL, LH, LL), breakout shapes, and optional ghost extensions.
- Extend lines right decides whether primary lines are truly extended to the right by TradingView’s line extension, or only drawn for the Start-End segment.
- Ghost Extend draws dotted, semi transparent projections for a configurable number of future bars when the main lines are not extended.
Deviation levels
- Deviation Multiplier and Deviation Levels add symmetric bands above and below the LOC, spaced by a distance derived from the channel height relative to LOC. These bands are projected along the channel slope.
Slope analysis and alerts
- The script can evaluate channel "strength" using either angle in degrees or a normalized percent-per-bar slope. The chosen measure is then bucketed into qualitative strength categories that are used only for labeling and alert message context.
- Alerts can be enabled for confirmed breakouts and for slope sign changes (bullish to bearish, or bearish to bullish).
How the channel baseline is constructed from Start to End
Once Start is reached, the script begins accumulating bar-by-bar statistics until End is reached:
- It tracks the number of bars in the selected range and accumulates an average and a linearly weighted average of closes.
- At End, it converts those aggregates into a straight line defined by a start value, an end value, and a per-bar slope across the Start-End period.
Why this works (within the chosen range):
- Using a fitted line over the selected segment provides a compact description of directional drift across that range. It will not capture every fluctuation, but it provides a stable reference for projecting "where the middle of the move is" as time advances.
How the channel height is determined and why the borders sit where they do
After computing the baseline slope, the script scans through the selected bars to measure how far price deviated above and below that baseline:
- For each bar in the range, it computes the baseline value at that bar index and measures the distance from that baseline to the bar’s high and to the bar’s low.
- It finds the maximum upward deviation and the maximum downward deviation.
- The baseline is shifted so the lower channel border is aligned to the worst downward deviation, and the total channel height becomes the distance between the worst upward and worst downward deviations.
Why this works (and what it implies):
- The resulting channel borders are anchored to the extremes observed in the selected range. That makes the borders a description of the range’s realized "envelope" around the fitted drift.
- Because this envelope is derived from past extremes in the chosen window, it is descriptive rather than predictive. When price behavior changes, future price can exceed the historical envelope and will be treated as a breakout.
How the volume profile is built inside the channel
The script constructs a volume profile that is aligned with the sloped channel, not a flat horizontal range:
- The channel’s vertical span is divided into the configured number of bins (Layers).
- For each bar in the selected range, the script checks which bins are intersected by that bar’s high-low range and adds that bar’s volume to each intersected bin.
- It keeps track of the bin with the highest accumulated volume. That bin defines the profile’s maximum-volume region.
Why this works (and what it measures):
- Aggregating volume by where price traded within the channel helps identify the areas where the most activity occurred during the selected move.
- Using bar range intersection (high-low crossing a bin) is a practical approximation for distributing volume across prices without requiring intrabar volume-at-price data. This approximation can over-attribute volume to multiple bins for wide bars, but it remains consistent across the range.
LOC, VAH, and VAL derivation
LOC (line of control)
- The LOC is placed at the center of the highest-volume bin.
- The LOC is then drawn as a line from Start to End, following the same slope as the channel baseline.
Interpretation:
- LOC represents the most frequently traded zone within the selected channel range, expressed as a sloped level that moves forward with the channel’s drift.
VAH and VAL
- Total volume across all bins is computed.
- Starting from the highest-volume bin, the script expands upward and downward, accumulating volume until the accumulated fraction exceeds the configured Volume Area %.
- The highest included bin boundary becomes VAH, and the lowest included bin boundary becomes VAL.
- VAH and VAL are drawn as sloped lines parallel to the channel drift.
Interpretation:
- VAH and VAL bound the portion of the channel where the majority of the range’s volume accumulated, based on the chosen percentage.
- Relative position of price to these levels can be used as context for whether current trading is occurring in historically high-activity or low-activity parts of the selected move.
Deviation bands around LOC
After LOC is known, the script creates additional parallel bands:
- It measures the vertical distance from LOC to the top channel border.
- Using that as a base offset, it draws symmetric lines above and below LOC for each deviation level, scaled by the deviation multiplier.
- These lines are projected with the same slope as the channel.
Interpretation:
- These bands provide repeated "distance markers" above and below LOC in units derived from the selected range’s internal structure.
- They are best treated as contextual zones rather than precise targets, because spacing is tied to the chosen Start-End window and its extremes.
Optional projections: Extend right and Ghost Extend
Two projection mechanisms exist:
- If Extend lines right is enabled, the main channel borders, LOC, and optionally VAH/VAL and deviation lines are extended using TradingView line extension.
- If Extend right is disabled but Ghost Extend is enabled, dotted projections are drawn for a fixed number of future bars from End, including channel borders, LOC, VAH/VAL, and deviation lines.
Interpretation:
- Both options visualize where the same fitted structure would land in future bars if slope remains unchanged. They do not update slope unless Start-End selection is changed.
Pivot labels: HH, HL, LH, LL
The script optionally labels local swing points using pivot detection:
- A pivot high is confirmed when a high is greater than neighboring highs by the configured left and right bar counts.
- A pivot low is confirmed similarly for lows.
- New pivot highs are labeled as HH or LH relative to the prior pivot high, and pivot lows as HL or LL relative to the prior pivot low.
- The logic includes a reset behavior after a new LL or HH to reduce chaining ambiguity across regime shifts.
Interpretation:
- These labels provide local structure context that can be compared to the channel’s direction and to whether price is interacting with channel borders or profile levels.
Breakout detection on channel borders
Once End is set, the channel is considered active and the script evaluates each new bar against the channel borders at that bar index:
- It computes the current top and bottom border values for the present bar by advancing from the Start baseline with the fitted slope and channel height.
- A potential breakout is marked on the first bar that crosses above the top border (or below the bottom border), using a close-based crossing test against the prior bar’s border value.
- After a potential breakout, the script waits for confirmation:
- For an upside breakout, confirmation occurs only if price remains above the top border and then closes higher than the potential breakout close.
- For a downside breakout, confirmation occurs only if price remains below the bottom border and then closes lower than the potential breakout close.
- If price re-enters back inside the border before confirmation, the pending breakout state is canceled.
Interpretation:
- The two-step logic distinguishes an initial border cross from follow-through. It aims to reduce cases where a single bar spikes outside the channel and immediately returns.
- The confirmation test is still close-based and does not consider intrabar excursions beyond the channel, so it is sensitive to candle closes rather than wicks.
Alerts included by the script
- Confirmed breakout up or down can trigger alerts and corresponding alertconditions, aligned to the confirmed state described above.
- Slope sign change alert triggers when the computed slope (based on the last selected Start-End range) flips sign compared to the previously computed slope. This is a re-selection or re-computation event rather than a continuous recalculation.
How to interpret the plotted elements together
A practical way to read the indicator is to separate it into three layers of information:
Channel structure
- Top and bottom borders describe the fitted envelope of the selected range.
- The slope indicates the drift direction implied by that selection.
Activity structure inside the channel
- LOC is the highest-activity region within the selected range, projected along drift.
- VAH and VAL bound the configured fraction of volume around the activity center.
- Deviation bands give repeated distance zones around LOC.
Event markers
- Pivot labels show local swing structure.
- Breakout markers highlight border crosses and confirmed follow-through.
How to best use this indicator
Selecting Start and End effectively
- Choose Start and End that represent a coherent swing segment where you want the channel and profile to describe that move.
- Avoid mixing multiple regimes (for example, including both a strong trend and a later choppy distribution) unless that is explicitly what you want the profile to summarize.
- If the selected window is extremely long, the script limits processing to recent data due to a hard cap (it warns when the range exceeds 10,000 bars and uses only the most recent subset).
Using LOC, VAH, and VAL for context
- Treat LOC as the "most traded" zone of the selected move, projected forward.
- Treat VAH and VAL as boundaries of the selected move’s high-activity region. Price acceptance inside VAH-VAL and excursions outside that band can be interpreted as trading in higher-activity versus lower-activity zones of the selected move.
Using breakouts
- A potential breakout is an early warning that the historical envelope is being exceeded on a closing basis.
- A confirmed breakout indicates follow-through beyond the initial breakout close while remaining outside the channel border.
Combining with pivot labels
- Compare HH/HL sequences to the channel slope to understand whether local structure aligns with the selected drift.
- Pivot labels can also help you decide when the current Start-End selection is no longer representative and should be refreshed.
Added value over other free indicators
- The volume profile is constructed along a sloped channel, not a flat horizontal range, so the distribution is expressed in the same coordinate frame as the selected drift.
- LOC, VAH, and VAL are therefore projected parallel to the channel, providing moving reference levels tied to the chosen swing segment rather than static horizontal bands.
- Breakout logic uses a two-step potential and confirmation mechanism, which separates first border crossings from subsequent follow-through conditions.
Disclaimers and where the indicator can fall short
- Results depend heavily on Start and End selection. Different anchor points can produce materially different slope, channel height, and profile levels.
- The volume profile uses candle range intersection to distribute volume across bins. Large range candles can contribute volume to many bins, which may broaden the apparent distribution.
- The channel borders are based on extremes within the selected range. If market volatility expands, price can exceed the envelope frequently and produce repeated breakout states.
- Breakout detection is close-based. Wick-only excursions beyond borders are not treated as breakouts unless the close crosses the border.
- Very large ranges may be truncated for processing due to the script’s internal bar limit, which changes what data is actually summarized.
Информация о релизе
This update introduces a new level of flexibility to the channel calculation logic by allowing users to decide whether candlestick wicks should be included or excluded when defining channel boundaries. By enabling wick inclusion, the channel becomes more sensitive to extreme price excursions, capturing full volatility spikes and liquidity grabs that occur beyond candle bodies. On the other hand, excluding wicks focuses the calculation strictly on candle bodies, resulting in a cleaner structure that better reflects sustained price acceptance rather than temporary rejections. This option gives traders greater control over how reactive or stable the channel behaves, making it easier to adapt the indicator to different market conditions and timeframes, whether the goal is to highlight aggressive breakout potential or to emphasize structurally confirmed price ranges.Информация о релизе
Cumulative DeltaThe Cumulative Delta is an optional order flow layer added to the script that tracks the net difference between buying and selling pressure over a selected range. It evaluates each candle’s internal structure and volume to estimate how much of the traded volume was driven by buyers versus sellers, then continuously accumulates that difference from the defined starting point. The result is a single evolving value that reflects whether aggressive participation has been dominantly bullish or bearish during the measured channel period.
How to use
As a feature, users can expect it to provide context behind price movement. A positive cumulative delta suggests sustained buying pressure, while a negative reading indicates dominant selling pressure. Displayed alongside the channel structure and slope, it helps confirm breakouts, validate trend strength, or highlight potential divergences when price moves in one direction but delta builds in the opposite. In practice, it acts as a pressure gauge - showing whether the move is backed by real participation or running on weakening momentum.
Информация о релизе
This update keeps the manually anchored channel workflow, but changes how the channel profile is calculated and adds new context around volume distribution, low-volume areas, delta, projected levels, styling, and alerts.The script still starts from the selected Start and End anchors. In this version the anchors are detected when price data crosses the selected times, rather than only when a bar timestamp exactly matches the input. This makes the selected range less dependent on whether the chart's bar timestamps match the chosen anchor time exactly.
Channel Source And Regression
The channel can now be calculated from either wicks or candle bodies. The Wicks preset uses high, low, and close values. The Bodies preset uses the candle body high, candle body low, and the body midpoint. This changes the price series used for the channel without changing the user's manual A to B workflow.
The regression calculation was also rebuilt around the active anchored range. The script calculates the channel from the selected A to B bars, limits the calculation window to the available maximum range, and then measures upper and lower channel distance from the selected source. This is useful because the same channel can now be built from full candle extremes or from body structure, depending on whether the user wants wick reactions or body acceptance to define the range.
Reworked Volume Profile
The volume profile now uses configurable rows instead of a fixed layer count. Each candle in the selected channel range is detrended against the channel base before its volume is distributed into profile rows. If only part of the candle range overlaps a row, only the proportional part of that candle's volume is added to that row.
This means the profile is calculated inside the sloping channel, not as a flat price histogram detached from the channel angle. The row with the largest accumulated volume becomes the LOC reference, and the value area is now calculated around that high-volume row using a fixed 70% value area. Rows inside the value area can use a separate color, while rows outside the value area keep the directional channel color.
The profile can also be drawn from either side of the selected range:
- Right of A draws profile rows forward from the start anchor.
- Left of B draws profile rows back toward the end anchor.
Ditch Zone
The update adds an optional Ditch zone. After the volume profile is built, the script searches for the longest continuous low-volume pocket whose normalized row volume is below the selected Ditch threshold.
When found, the Ditch is drawn as a sloped zone inside the same channel grid, with optional midpoint, fill, label, and projection. The reason for this calculation is that a value area can contain uneven participation. The Ditch marks a thinner-volume area inside the channel where the script found less traded volume relative to the highest-volume row.
Delta Additions
The script now estimates directional volume from each candle's body and wick proportions. That estimated delta is accumulated from the Start anchor and shown as a cumulative delta label after the End anchor.
The same per-row volume distribution also builds a delta profile. From that profile the script can mark:
- +DPOC: the channel row with the strongest positive estimated delta.
- -DPOC: the channel row with the strongest negative estimated delta.
These delta rows use the same sloped channel coordinates as the volume profile. This is the added value of including delta in the channel script: the volume area, LOC, Ditch, and delta POC levels all come from the same anchored channel range instead of being separate readings from unrelated tools.
Deviation And Projection Changes
Deviation lines now have a preset selector. The LOC Symmetric preset places deviations at equal distances around LOC using the smaller available distance to the channel border. Channel Half uses half of the full channel height. Top Edge Legacy keeps the previous top-edge style distance.
Ghost projection was expanded to include more of the new calculated levels. When ghost extension is enabled and normal right extension is disabled, the script can project the channel borders, LOC, VAH/VAL, +DPOC, -DPOC, and Ditch boundaries forward by the selected number of bars.
Style And Label Controls
The update adds line width and line style controls for LOC, VAH/VAL, and delta POC lines. LOC, Ditch, +DPOC, and -DPOC can also show right-side labels connected by short dotted guide lines.
Object handling was changed so the script deletes and redraws the last calculated lines and labels on the last bar. This keeps the visual state tied to the current selected channel range and reduces leftover objects when settings or anchors change.
Alerts
The original channel breakout logic remains based on potential and confirmed breaks of the projected channel border. This update adds separate volume-profile alert conditions:
- Close above projected VAH.
- Close below projected VAL.
- LOC reclaim up.
- Ditch touch.
These alerts use the calculated channel slope to project the selected level from the End anchor to the current bar. They should be read as notifications that price is interacting with a calculated channel-profile level, not as complete trading instructions.
How To Use The Updated Parts
- Use the Channel Source preset to decide whether the channel should react to full wicks or candle bodies.
- Use VP Rows to control profile resolution. Higher row counts give more detail but can make the chart denser.
- Use VP Side to place the profile where it is easier to read relative to the selected A to B range.
- Use the Ditch zone to identify the largest low-volume pocket found inside the channel profile.
- Compare LOC, VAH/VAL, Ditch, +DPOC, and -DPOC because they are all calculated from the same anchored channel.
- Use deviation presets when the old deviation distance does not match the intended interpretation of the channel.
- Use the new VP alerts as prompts to inspect price action around projected channel-profile levels.
The ZenAlgo team
zenalgo.com
discord.zenalgo.com
zenalgo.com
discord.zenalgo.com
Отказ от ответственности
Информация и публикации не предназначены для предоставления и не являются финансовыми, инвестиционными, торговыми или другими видами советов или рекомендаций, предоставленных или одобренных TradingView. Подробнее читайте в Условиях использования.
The ZenAlgo team
zenalgo.com
discord.zenalgo.com
zenalgo.com
discord.zenalgo.com
Отказ от ответственности
Информация и публикации не предназначены для предоставления и не являются финансовыми, инвестиционными, торговыми или другими видами советов или рекомендаций, предоставленных или одобренных TradingView. Подробнее читайте в Условиях использования.