RK's 13 - Moving Average with Fibonacci Lines
Jan 8, 2021

The RK's 13 - Moving Average with Fibonacci Lines indicator calculates dynamic support and resistance levels by applying Fibonacci ratios to the difference between fast and slow moving averages. This tool provides traders with precise price targets for exit points, stop-loss placement, and trend exhaustion zones.
Usage
The indicator can be used to identify key pivot zones and trend extensions. By calculating the spread between two moving averages, it projects Fibonacci-based levels that act as magnet or rejection zones.
- Exit and Stop Placement: Use the major retracement levels (0.382, 0.618) to set stop-loss orders or take-profit targets during trend pullbacks.
- Trend Extensions: Major extension levels (1.236, 1.618) serve as objective targets during strong trending phases when the fast and slow moving averages are widely separated.
- Reversal Identification: The "Reverse Lines" option allows users to flip the calculation logic, which can be useful for finding contrarian levels or adapting to specific asset behaviors.
- Visual Analysis: Enabling "Project Moving Average Lines in the Future" provides a visual trajectory of the trend direction based on recent momentum.
Details
The script functions by first calculating two user-defined moving averages (Fast and Slow). It then determines the "Difference" between these two values. Fibonacci ratios are applied to this difference and then added back to the Fast Moving Average to plot various levels on the chart.
The tool includes several categories of levels:
- Major Retracement: Standard ratios used to identify pullbacks within a trend.
- Major Extension: Ratios used to project price movement beyond the current range.
- Mid Levels: Includes the 0.50, 1.00, and 2.00 levels for psychological rounding and full-range extensions.
- Minor Levels: Specialized ratios like 0.146 and 4.236 for high-precision entries or extreme trend exhaustion.
The effectiveness of these levels is typically higher when the moving average lines are well-dispersed, indicating a clear trend is in progress.
Settings
General Settings
- Source List: Determines the price data used for the moving average calculations (e.g., Close, Open, High, Low).
- Moving Average Type: Select between SMA, EMA, RMA, HMA, WMA, or SWMA.
- Fast Length: The period for the short-term moving average.
- Slow Length: The period for the long-term moving average.
- Reverse Lines: Inverts the calculation of the difference between the two moving averages.
Fibonacci Levels
- Major Retracement Levels: Toggle specific ratios including 0.236, 0.382, 0.618, and 0.764.
- Major Extension Levels: Toggle specific ratios including 1.236, 1.382, 1.618, and 2.618.
- Mid Retracement and Extension Levels: Toggle 0.500, 1.000, 1.500, and 2.000.
- Minor Levels: Toggle precision ratios such as 0.146, 0.854, 3.236, and 4.236.
Visuals
- Show Labels: Displays text labels for each active Fibonacci ratio on the chart.
- Draw Line Labels: Sets the size of the text labels (Tiny to Huge).
- Labels Offset Position: Adjusts how far to the right of the current bar the labels are placed.
- Project Moving Average Lines in the future: Extends the MA lines forward to visualize potential price paths.
FAQ
How do I access RK's 13 - Moving Average with Fibonacci Lines?
You can get access on the LuxAlgo Library for charting platforms like TradingView, MetaTrader (MT4/MT5), and NinjaTrader for free.
Which moving average type is best for this indicator?
The EMA (Exponential Moving Average) is often preferred for more reactive levels, while the SMA (Simple Moving Average) provides smoother, more conservative support and resistance zones.
Why are the levels not appearing on my chart?
Ensure that the "Show Labels" setting is enabled and that you have selected at least one ratio from the Major, Mid, or Minor level groups in the settings menu.
Free indicator
Get free access to this indicator on the platforms below.
Unlock the entire LuxAlgo Library
Every indicator, every strategy, full charts, and complete access to Quant — our AI agent.