This strategy calculates a smoothed Relative Strength Index and plots self-adjusting linear regression bands with overbought and oversold boundaries in a separate pane.
1Copy the scriptPress Copy script above. It reads the file straight from GitHub.
2Open the Pine EditorOpen a TradingView chart and choose Pine Editor at the bottom of the screen.
3Paste over the templateCreate a new strategy, select all of the template text and paste. Press Save and give it a name.
4Add it to the chartPress Add to chart. The trades and results appear in the Strategy Tester tab; adjust the settings with the gear icon.
Source Code
The code stays on GitHub. The author has not published this script under an open licence, so ForexR does not show its code. Copy script reads the file straight from GitHub into your clipboard, so you can still try it on your own chart. Ask the author before reusing the code anywhere else.
Overview
BTC Cycle RSI + LinReg Bands DCA Strategy enters long positions through dollar-cost averaging orders scaled across market phases and supported by an optional yield pool. Exits occur via sequential sell orders triggered after RSI peaks and midline breakdowns. Key settings adjust the RSI lookback, regression length, deviation multiplier, DCA allocation, and yield deployment rates. The strategy operates without a default stop-loss mechanism.
Self-adjusting linear regression bands on RSI
Yield-funded dollar-cost averaging mechanism
Sequential profit-taking sell signals
Configurable overbought and oversold cycle thresholds
The inputs you can change from the gear icon on the chart. Defaults are the author's.
Setting
Type
Default
Variable
Use start date filter
bool
true
useStartDate
Start Year
int
2013
startYear
Start Month
int
1
startMonth
Start Day
int
1
startDay
RSI Source
source
close
rsi_src_
RSI Length
int
50
len
LinReg Period
int
200
period
Deviation
float
2.0
deviations
Overbought
int
65
obLevel
Oversold
int
35
osLevel
Base DCA Amount (1x, USD)
float
100
baseDCA
Require prior RSI > Overbought for sell signals?
bool
true
useFalseFilter
Show all 24 settings
Setting
Type
Default
Variable
Enable DCA buys
bool
true
enableDCA
Enable sequential sells
bool
true
enableSells
Yield basket APR (%)
float
11.0
yieldApr
Starting yield basket balance (USD)
float
0.0
startingYieldBalance
Enable yield-funded DCA
bool
true
yieldDCAEnabled
Deep bear: target % of starting yield to keep
float
20.0
deepBearTargetFrac
Max deploy per week (% of yield pool)
float
4.0
hybridMaxPctPool
Deploy % of remaining pool per week
float
25.0
hybridDeployPct
Weeks to ramp to full capacity
float
25.0
hybridRampWeeks
Starting capacity (%)
float
10.0
hybridStartCapacity
Drawdown scaling exponent
float
3.0
hybridDrawdownPower
Show sell signal icons
bool
true
showSellIcons
Third-party code. ForexR did not write, test or endorse this script, and the summary above was generated automatically from its code and README. Indicators describe the past, and a strategy's backtest can look better than live trading, especially when a script repaints. Check it in the Strategy Tester and on a demo account before you rely on it.
This strategy combines Larry Williams' Vix Fix synthetic volatility indicator with Bollinger Bands. It calculates standard and inverted Williams Vix Fix metrics, displaying them as histogram columns with standard deviation bands in a separate pane. Long entrie
This strategy executes mean-reversion trades based on Bollinger Bands and the Stochastic Oscillator. Long orders trigger when price dips below the lower band alongside a bullish Stochastic crossover, with an optional oversold threshold. Short orders execute on
This strategy fades Bollinger Band extremes using the close. It enters short when price crosses above the upper band and the 14-period RSI is above 70, and enters long when price crosses below the lower band and RSI is below 30. It closes half of an open short
This strategy combines Bollinger Bands with a short RSI to fade moves that leave the bands and then return. A long requires the prior bar below the lower band and oversold, then a close back inside the band while RSI is between 30 and 50. Shorts mirror that at
This strategy overlays the price chart to trade DAX futures during European market hours. It calculates exponential and simple moving averages, RSI, MACD, Bollinger Bands, ATR, and realized volatility to simulate VIX levels. Trades execute when session time fi
Calculates a combination of the Relative Strength Index, MACD histogram, and Bollinger Bands contraction to identify long trade entries. The strategy signals a long position on a bullish bar when the MACD histogram turns upward while negative, RSI remains belo