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 indicator, select all of the template text and paste. Press Save and give it a name.
4Add it to the chartPress Add to chart, then adjust the settings with the gear icon next to its name.
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
ML Price Predictor (KNN) measures RSI, RSI slope, volume relative to a 20-bar average, EMA trend strength, and price position within a range, each scaled by a user weight. From the nearest matches it estimates direction and a target several bars ahead, then draws a label, an optional target line, EMA lines, and buy or sell markers when confidence meets a minimum. A confidence histogram can be shown. No stop, exit, or position rules are included because it is an indicator.
K-nearest neighbors historical pattern search
Weighted RSI, volume, trend and price-position features
Adjustable lookback and prediction horizon
Buy and sell markers with minimum confidence
Target price line, label, EMA lines and confidence histogram
The inputs you can change from the gear icon on the chart. Defaults are the author's.
Setting
Type
Default
Variable
Historical Lookback Bars
int
100
lookback_bars
K Nearest Neighbors
int
10
k_neighbors
Predict N Bars Ahead
int
10
prediction_horizon
RSI Weight
float
1.0
weight_rsi
Volume Weight
float
0.8
weight_volume
Trend Weight
float
1.2
weight_trend
Price Position Weight
float
1.0
weight_price_pos
Show Prediction Label
bool
true
show_prediction_label
Panel Position
string
Top Right
panel_position
Show Target Price Line
bool
true
show_target_line
Show Buy/Sell Signals
bool
true
show_signals
Min Confidence for Signals (%)
int
50
min_confidence
Show all 14 settings
Setting
Type
Default
Variable
Show EMA Lines
bool
true
show_ema
Show Confidence Histogram
bool
false
show_conf_histogram
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 overlay indicator marks call and put setups from EMAs, RSI, MACD, and a SPY volume ratio. A call needs higher highs, RSI above its minimum, rising MACD, above-average proxy volume, and a rising trend EMA; a put reverses those tests. Early markers use an E
LiqSpikeBounceLong Feb2026 is an indicator designed to identify long bounce entries following high-volume liquidation cascades in bearish market contexts. It checks if price is below an exponential moving average, then detects large single-bar drops exceeding
Volume Weighted Distance applies statistical and machine learning distance metrics between source prices and their rolling mean, weighted by volume, to identify local trend reversals. Users can select from Manhattan, Euclidean, Mahalanobis, Cosine Similarity,
This indicator generates trend-following trade signals on the price chart by combining moving average crossovers with multi-factor filters. It triggers entry alerts when fast and slow EMAs cross in the direction of a baseline trend EMA, confirmed by non-extrem
This overlay indicator plots a SuperTrend using a 10-period ATR with a multiplier of 3, drawing up and down stop lines and a faint trend fill on the price chart. It compares a 9-period EMA with an 18-period EMA and a 12/26/9 MACD against its signal, and it req
Bte Acc is a chart indicator form of the PineCoders Backtesting and Trading Engine. It seeks an entry trigger from a main or alternate entry method, then checks trade direction, filters, date range, ATR readiness, and remaining capital before filling on the ne