OPEN-SOURCE SCRIPT
Fibonacci + RSI - Strategy

Overview
This is an intraday mean-reversion strategy designed for short timeframes (1–30 minutes).
It combines volatility-based Fibonacci bands with RSI momentum signals to identify temporary price extremes and trade pullbacks back toward fair value.
The strategy trades both long and short, uses limit entries, a manual exit logic, and a hard stop-loss as risk protection.
Market Context
The strategy assumes that, on intraday timeframes:
price frequently deviates from its short-term fair value,
extreme deviations tend to revert,
momentum (RSI) can confirm exhaustion.
It is not a trend-following system.
Trades are taken against short-term extremes, not in the direction of breakouts.
Indicators Used
1. Fibonacci Volatility Bands
The bands are calculated using:
VWMA (Volume Weighted Moving Average) as the central price,
Standard Deviation as a volatility measure,
a multiplier to create upper and lower bands.
Key levels:
Upper Band (fu1) – overextended price zone
Lower Band (fd1) – oversold price zone
Intermediate targets (fu764 / fd764) – mean-reversion profit targets
These bands behave similarly to dynamic volatility channels.
2. RSI (Relative Strength Index)
RSI length: typically 14
Oversold level: 30
Overbought level: 70
The strategy uses RSI crossovers to confirm momentum reversal:
crossing up from oversold → potential long
crossing down from overbought → potential short
Entry Rules
Long Entry
A long position is considered when:
Price trades below the lower Fibonacci band (fd1)
RSI crosses upward from the oversold level
Price is still below the predefined upside target
The trade is entered using a limit order at the candle close.
Short Entry
A short position is considered when:
Price trades above the upper Fibonacci band (fu1)
RSI crosses downward from the overbought level
Price is still above the predefined downside target
The trade is entered using a limit order at the candle close.
Exit Rules
Manual Exit (Primary Exit)
Positions are closed manually when price reaches predefined Fibonacci target levels:
Long: price moves back up into the target zone
Short: price moves back down into the target zone
This exit represents the mean-reversion objective of the strategy.
Stop-Loss (Risk Protection)
A hard stop-loss is always active to protect against adverse moves.
Long stop: below entry price
Short stop: above entry price
The stop is calculated as a fixed percentage (or ATR-based in later versions) from the entry price.
The stop-loss is not the primary exit, but a safety mechanism.
Order Management Philosophy
Limit entries are used to avoid market slippage.
Manual exits control trade logic.
Stop-loss exits control risk only.
Only one position per direction is managed at a time.
Alerts are generated at signal or entry time for automation or monitoring.
Risk & Characteristics
Designed for frequent, small trades
Low average drawdown per trade
Performance depends heavily on:
volatility regime
correct stop sizing
disciplined risk management
Without proper position sizing, the strategy must not be traded live.
Suitable Markets
Forex pairs
Indices
Liquid crypto pairs
Best performance is expected in ranging or mildly trending markets.
Summary
This strategy attempts to exploit short-term price overextensions by combining volatility bands with momentum confirmation.
It relies on mean reversion, controlled risk, and disciplined execution rather than large directional moves.
This is an intraday mean-reversion strategy designed for short timeframes (1–30 minutes).
It combines volatility-based Fibonacci bands with RSI momentum signals to identify temporary price extremes and trade pullbacks back toward fair value.
The strategy trades both long and short, uses limit entries, a manual exit logic, and a hard stop-loss as risk protection.
Market Context
The strategy assumes that, on intraday timeframes:
price frequently deviates from its short-term fair value,
extreme deviations tend to revert,
momentum (RSI) can confirm exhaustion.
It is not a trend-following system.
Trades are taken against short-term extremes, not in the direction of breakouts.
Indicators Used
1. Fibonacci Volatility Bands
The bands are calculated using:
VWMA (Volume Weighted Moving Average) as the central price,
Standard Deviation as a volatility measure,
a multiplier to create upper and lower bands.
Key levels:
Upper Band (fu1) – overextended price zone
Lower Band (fd1) – oversold price zone
Intermediate targets (fu764 / fd764) – mean-reversion profit targets
These bands behave similarly to dynamic volatility channels.
2. RSI (Relative Strength Index)
RSI length: typically 14
Oversold level: 30
Overbought level: 70
The strategy uses RSI crossovers to confirm momentum reversal:
crossing up from oversold → potential long
crossing down from overbought → potential short
Entry Rules
Long Entry
A long position is considered when:
Price trades below the lower Fibonacci band (fd1)
RSI crosses upward from the oversold level
Price is still below the predefined upside target
The trade is entered using a limit order at the candle close.
Short Entry
A short position is considered when:
Price trades above the upper Fibonacci band (fu1)
RSI crosses downward from the overbought level
Price is still above the predefined downside target
The trade is entered using a limit order at the candle close.
Exit Rules
Manual Exit (Primary Exit)
Positions are closed manually when price reaches predefined Fibonacci target levels:
Long: price moves back up into the target zone
Short: price moves back down into the target zone
This exit represents the mean-reversion objective of the strategy.
Stop-Loss (Risk Protection)
A hard stop-loss is always active to protect against adverse moves.
Long stop: below entry price
Short stop: above entry price
The stop is calculated as a fixed percentage (or ATR-based in later versions) from the entry price.
The stop-loss is not the primary exit, but a safety mechanism.
Order Management Philosophy
Limit entries are used to avoid market slippage.
Manual exits control trade logic.
Stop-loss exits control risk only.
Only one position per direction is managed at a time.
Alerts are generated at signal or entry time for automation or monitoring.
Risk & Characteristics
Designed for frequent, small trades
Low average drawdown per trade
Performance depends heavily on:
volatility regime
correct stop sizing
disciplined risk management
Without proper position sizing, the strategy must not be traded live.
Suitable Markets
Forex pairs
Indices
Liquid crypto pairs
Best performance is expected in ranging or mildly trending markets.
Summary
This strategy attempts to exploit short-term price overextensions by combining volatility bands with momentum confirmation.
It relies on mean reversion, controlled risk, and disciplined execution rather than large directional moves.
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。
开源脚本
秉承TradingView的精神,该脚本的作者将其开源,以便交易者可以查看和验证其功能。向作者致敬!您可以免费使用该脚本,但请记住,重新发布代码须遵守我们的网站规则。
免责声明
这些信息和出版物并非旨在提供,也不构成TradingView提供或认可的任何形式的财务、投资、交易或其他类型的建议或推荐。请阅读使用条款了解更多信息。