OPEN-SOURCE SCRIPT
Sloping Channels and Grid Drag/Drop

Sloping Channels and Grid Drag/Drop
This indicator plots a set of parallel, sloped projection lines anchored to a single point in time that you choose. Instead of the usual flat horizontal channel, the lines slope forward at a rate you define — either as a fixed percentage per day or a custom slope — so the channel tracks a directional bias rather than a static range.
How it works
Pick an anchor point with the time input. The script locks onto the price at that bar and builds everything from there.
Choose a slope (0–1, with a flip-to-negative option) to set the angle of the projection.
Set a band type — Percent, ATR, or Fixed value — to control the spacing between the base line and the outer bands. Five bands are plotted on each side.
Optionally enable Grid mode to overlay a second, mirrored set of lines (opposite slope) shifted by a multiple of the band width. This is particularly useful for visualizing symmetry between uptrend and downtrend structure around the same anchor.
A vertical marker line highlights your anchor point, and a small info table in the corner shows current band width and active slope.
Why sloped lines instead of flat channels
Flat horizontal channels don't account for underlying drift. Forex pairs in particular tend to respond well to predetermined, consistent slope angles rather than freshly-fitted trendlines — a fixed daily-rate slope often tracks price behavior more reliably than manually redrawing a channel each session. By anchoring a slope to a chosen reference point, this tool lets you project that directional expectation forward and see, in real time, how price behaves relative to it.
Suggested slope settings
For forex, slope values around 0.15, 0.5, and 1 (% per day) tend to work well as starting points. Stocks typically require different values given their different volatility and drift characteristics — treat the presets as a forex-tuned starting point, not a universal default.
Easier than a standard channel
Most channel tools require you to set three points (two to define the trendline, one for the offset) and manually redraw as price evolves. This indicator only needs one anchor point — the slope, spacing, and projection are handled automatically from there.
Notes
Lines are drawn using line.new() with extend.both, so once anchored, they persist and project infinitely in both directions — no repainting from redraws each bar.
Designed for intraday use but the timeframe multiplier scales the slope correctly across timeframes.
Grid shift factor lets you offset the secondary set by up to 2x the band width, without needing a second anchor.
This indicator plots a set of parallel, sloped projection lines anchored to a single point in time that you choose. Instead of the usual flat horizontal channel, the lines slope forward at a rate you define — either as a fixed percentage per day or a custom slope — so the channel tracks a directional bias rather than a static range.
How it works
Pick an anchor point with the time input. The script locks onto the price at that bar and builds everything from there.
Choose a slope (0–1, with a flip-to-negative option) to set the angle of the projection.
Set a band type — Percent, ATR, or Fixed value — to control the spacing between the base line and the outer bands. Five bands are plotted on each side.
Optionally enable Grid mode to overlay a second, mirrored set of lines (opposite slope) shifted by a multiple of the band width. This is particularly useful for visualizing symmetry between uptrend and downtrend structure around the same anchor.
A vertical marker line highlights your anchor point, and a small info table in the corner shows current band width and active slope.
Why sloped lines instead of flat channels
Flat horizontal channels don't account for underlying drift. Forex pairs in particular tend to respond well to predetermined, consistent slope angles rather than freshly-fitted trendlines — a fixed daily-rate slope often tracks price behavior more reliably than manually redrawing a channel each session. By anchoring a slope to a chosen reference point, this tool lets you project that directional expectation forward and see, in real time, how price behaves relative to it.
Suggested slope settings
For forex, slope values around 0.15, 0.5, and 1 (% per day) tend to work well as starting points. Stocks typically require different values given their different volatility and drift characteristics — treat the presets as a forex-tuned starting point, not a universal default.
Easier than a standard channel
Most channel tools require you to set three points (two to define the trendline, one for the offset) and manually redraw as price evolves. This indicator only needs one anchor point — the slope, spacing, and projection are handled automatically from there.
Notes
Lines are drawn using line.new() with extend.both, so once anchored, they persist and project infinitely in both directions — no repainting from redraws each bar.
Designed for intraday use but the timeframe multiplier scales the slope correctly across timeframes.
Grid shift factor lets you offset the secondary set by up to 2x the band width, without needing a second anchor.
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。