Penunjuk dan strategi
Cointegration Heatmap & Spread Table [EdgeTerminal]The Cointegration Heatmap is a powerful visual and quantitative tool designed to uncover deep, statistically meaningful relationships between assets.
Unlike traditional indicators that react to price movement, this tool analyzes the underlying statistical relationship between two time series and tracks when they diverge from their long-term equilibrium — offering actionable signals for mean-reversion trades .
What Is Cointegration?
Most traders are familiar with correlation, which measures how two assets move together in the short term. But correlation is shallow — it doesn’t imply a stable or predictable relationship over time.
Cointegration, however, is a deeper statistical concept: Two assets are cointegrated if a linear combination of their prices or returns is stationary , even if the individual series themselves are non-stationary.
Cointegration is a foundational concept in time series analysis, widely used by hedge funds, proprietary trading firms, and quantitative researchers. This indicator brings that institutional-grade concept into an easy-to-use and fully visual TradingView indicator.
This tool helps answer key questions like:
“Which stocks tend to move in sync over the long term?”
“When are two assets diverging beyond statistical norms?”
“Is now the right time to short one and long the other?”
Using a combination of regression analysis, residual modeling, and Z-score evaluation, this indicator surfaces opportunities where price relationships are stretched and likely to snap back — making it ideal for building low-risk, high-probability trade setups.
In simple terms:
Cointegrated assets drift apart temporarily, but always come back together over time. This behavior is the foundation of successful pairs trading.
How the Indicator Works
Cointegration Heatmap indicator works across any market supported on TradingView — from stocks and ETFs to cryptocurrencies and forex pairs.
You enter your list of symbols, choose a timeframe, and the indicator updates every bar with live cointegration scores, spread signals, and trade-ready insights.
Indicator Settings:
Symbol list: a customizable list of symbols separated by commas
Returns timeframe: time frame selection for return sampling (Weekly or Monthly)
Max periods: max periods to limit the data to a certain time and to control indicator performance
This indicator accomplishes three major goals in one streamlined package:
Identifies stable long-term relationships (cointegration) between assets, using a heatmap visualization.
Tracks the spread — the difference between actual prices and the predicted linear relationship — between each pair.
Generates trade signals based on Z-score deviations from the mean spread, helping traders know when a pair is statistically overextended and likely to mean revert.
The math:
Returns are calculated using spread tickers to ensure alignment in time and adjust for dividends, splits, and other inconsistencies.
For each unique pair of symbols, we perform a linear regression
Yt=α+βXt+ε
Then we compute the residuals (errors from the regression):
Spreadt=Yt−(α+βXt)
Calculate the standard deviation of the spread over a moving window (default: 100 samples) and finally, define the Cointegration Score:
S=1/Standard Deviation of Residuals
This means, the lower the deviation, the tighter the relationship, so higher scores indicate stronger cointegration.
Always remember that cointegration can break down so monitor the asset over time and over multiple different timeframes before making a decision.
How to use the indicator
The heatmap table:
The indicator displays 2 very important tables, one in the middle and one on the right side. After entering your symbols, the first table to pay attention to is the middle heatmap table.
Any assets with a cointegration value of 25% is something to pay attention to and have a strong and stable relationship. Anything below is weak and not tradable.
Additionally, the 40% level is another important line to cross. Assets that have a cointegration score of over 40% will most likely have an extremely strong relationship.
Think about it this way, the higher the percentage, the tighter and more statistically reliable the relationship is.
The spread table:
After finding a good asset pair using heatmap, locate the same pair in the spread table (right side).
Here’s what you’ll see on the table:
Spread: Current difference between the two symbols based on the regression fit
Mean: Historical average of that spread
Z-score: How far current spread is from the mean in standard deviations
Signal: Trade suggestion: Short, Long, or Neutral
Since you’re expecting mean reversion, the idea is that the spread will return to the average. You want to take a trade when the z-score is either over +2 or below -2 and exit when z-score returns to near 0.
You will usually see the trade suggestion on the spread chart but you can make your own decision based on your risk level.
Keep in mind that the Z-score for each pair refers to how off the first asset is from the mean compared to the second one, so for example if you see STOCKA vs STOCKB with a Z-score of -1.55, we are regressing STOCKB (Y) on STOCKA (X).
In this case, STOCKB is the quoted asset and STOCKA is the base asset.
In this case, this means that STOCKB is much lower than expected relative to STOCKA, so the trade would be a long position on stock B and short position on stock A.
4 EMA Modified [Ryu_xp] - Enhanced4 EMA Modified – Enhanced (Pine v6)
A highly configurable, four-line exponential moving average (EMA) overlay built in Pine Script v6. This indicator empowers traders to monitor short- and long-term trends simultaneously, with the ability to toggle each EMA on or off and adjust its period and data source—all from a single, inline control panel.
Key Features:
Pine Script v6: updated to leverage the latest performance improvements and language features.
Four EMAs:
EMA 3 for ultra-short momentum (white, medium line)
EMA 10 for short-term trend (light blue, thin line)
EMA 55 for intermediate trend (orange, thicker line)
EMA 200 for long-term trend (dynamic green/red, thickest line)
Inline Controls: Each EMA has its own checkbox, length input, and source selector arranged on a single line for fast configuration.
Dynamic Coloring: EMA 200 switches to green when price is above it (bullish) and red when price is below it (bearish).
Toggle Visibility: Enable or disable any EMA instantly without removing it from your chart.
Clean Overlay: All EMAs plotted in one pane; ideal for multi-timeframe trend confluence and crossover strategies.
Inputs:
Show/Hide each EMA
EMA Length and Source for periods 3, 10, 55, and 200
Usage:
Add the script to any price chart.
Use the inline checkboxes to show only the EMAs you need.
Adjust lengths and sources to fit your instrument and timeframe.
Watch for crossovers between EMAs or price interactions with EMA 200 to confirm trend shifts.
This open-source script offers maximum flexibility for traders seeking a customizable EMA toolkit in one simple overlay.
Linda MACD Divergence w/ Lines + Cam FilterThis is an improvement on the first. Pay around with the Diff setting and do some backtesting. you could try traditional macd settings but the Linda's divergence is the secret to this set up.
ADX Pro [Ryu_xp] - EnhancedADX Pro – Enhanced (Pine v6)
A modernized ADX indicator built in Pine Script v6, combining customizable trend-strength thresholds with optional DI plotting, candle coloring, and a built-in label table for at-a-glance readings. Designed to give traders precise entry signals and market-condition awareness in one clean pane.
Key Features:
Fully Updated to Pine v6: Leverages the latest Pine Script features for speed and reliability.
Adjustable Trend Levels: Define your own “Disinterest” (default 20) and “Strong Trend” (default 35) levels to suit any instrument or timeframe.
Monocolor Mode: Override dynamic coloring and choose a single ADX line color for a minimalistic look.
Optional +DI/–DI Plotting: Toggle directional indicators on or off without modifying the code.
Candle Coloring: Barcolors reflect current ADX strength zone, making trend bias instantly visible on price.
45° Direction Arrow: Easily read whether ADX is rising (↗) or falling (↘) without needing to inspect values.
Live Status Table: A compact, right-aligned table displays the current ADX value, arrow, and label “ADX” in a colored cell—fully resizable to your chart layout.
Built-in Alerts:
Strong Trend Alert when ADX ≥ trend level.
Disinterest Alert when ADX < range level.
Usage:
Apply to any chart on a clean pane (no extra indicators).
Configure “Disinterest” and “Trend” levels as desired.
Enable monocolor or DI plots if needed.
Watch live table and bar colors for quick decision-making.
Set up alerts to automate your strategy triggers.
Multi-Timeframe RSI Divergenceweekly RSI divergence indicator. marking are made on chart for bullish and bearish indication on charts. suggestion for improvement are welcomed for refinement.
Weekly RSI DivergenceMarks divergences on price and RSI on price chart. arrows arrears where DIVERGENCE occcure. green indicates bullish red is bearish. to be cross checked with price and used. any suggeston is welcome
Smooth Fibonacci BandsSmooth Fibonacci Bands
This indicator overlays adaptive Fibonacci bands on your chart, creating dynamic support and resistance zones based on price volatility. It combines a simple moving average with ATR-based Fibonacci levels to generate multiple bands that expand and contract with market conditions.
## Features
- Creates three pairs of upper and lower Fibonacci bands
- Smoothing option for cleaner, less noisy bands
- Fully customizable colors and line thickness
- Adapts automatically to changing market volatility
## Settings
Adjust the SMA and ATR lengths to match your trading timeframe. For short-term trading, try lower values; for longer-term analysis, use higher values. The Fibonacci factors determine how far each band extends from the center line - standard Fibonacci ratios (1.618, 2.618, and 4.236) are provided as defaults.
## Trading Applications
- Use band crossovers as potential entry and exit signals
- Look for price bouncing off bands as reversal opportunities
- Watch for price breaking through multiple bands as strong trend confirmation
- Identify potential support/resistance zones for placing stop losses or take profits
Fibonacci Bands combines the reliability of moving averages with the adaptability of ATR and the natural market harmony of Fibonacci ratios, offering a robust framework for both trend and range analysis.
Cash Market Volatility StrategyBCM - Baycam
Brakout signals based on voltality parameters -
Closing price
ATR - Average true range
RSI
Crypto Scalping Strategy [Dubic] - LONG OnlyCrypto Scalping Strategy is a high-frequency trading tool designed for scalping volatile crypto pairs like PEPE/USDT on Binance. It features EMA crossover-based entries, volume-confirmed re-entries, fixed take profit (0.10%), trailing take profit (0.01%), and trailing stop loss (0.01%). Alerts are webhook-ready for seamless integration with trading bots. Optimized for fast, responsive trades in trending markets.
EMA CCI SSL Buy Sell Signal [THANHCONG]📘 Full Description
🔍 Overview
This indicator combines three key technical elements to generate trend-based buy/sell signals:
EMA (Exponential Moving Averages), CCI (Commodity Channel Index), and the SSL Channel.
📊 Key Features:
✅ Multi-timeframe EMA alignment (8, 21, 89) to confirm trend direction
✅ CCI to detect short-term momentum shifts
✅ Higher Time Frame (HTF) SSL Channel integration for trend filtering
✅ Automatic HTF detection (Auto Mode) or manual timeframe selection
✅ On-chart visual signals with labels and clear color cues
✅ Signal info panel displaying real-time profit/loss percentage since entry
⚙️ Signal Logic
Buy Signal:
EMA 8 > EMA 21 > EMA 89 (strong uptrend)
Turbo CCI > 50 (bullish momentum)
Price crosses above HTF SSL upper band
Sell Signal:
EMA 8 < EMA 21 < EMA 89 (strong downtrend)
Turbo CCI < -50 (bearish momentum)
Price crosses below HTF SSL lower band
💡 Highlights:
Early signals: Displayed immediately once conditions are met (no candle close required)
Flexible HTF filtering (Auto/Manual option)
Optimized for use on 15-minute to 4-hour or daily charts
📌 How to Use:
Apply the indicator on charts from 15-minute timeframe and above
Watch for "Buy Signal" or "Sell Signal" labels to appear on the chart
Combine with your own analysis and trade management strategy
Optional: backtest on historical data for confirmation
⚠️ Disclaimer (as per TradingView policy):
This tool does not constitute financial advice or guarantee profits.
Users should test thoroughly and manage risk appropriately.
Past performance does not guarantee future results.
This script is original and manually coded, inspired by well-known methods, without direct copying from any other public or private source.
✅ Author & License:
Author: @ThanhCong_
License: Mozilla Public License 2.0
🙏 Thank you for using this indicator!
If you find it helpful, feel free to leave a comment, share it with others, or follow me for future updates and tools.
Happy and safe trading! 🚀📈..
Improved RSI with Divergence + Gradient + Trend HistogramThis will:
Restrict the y-axis to start at 0
Prevent any accidental -40 scale drops
You can now safely reintroduce the histogram bars without breaking the scale.
Let me know if you want to move the histogram to a separate pane or adjust its bar thickness/gradient.
MACDtechnical analysis. It consists of three components:
MACD Line: Calculated by subtracting the 26-period EMA from the 12-period EMA.
Signal Line: A 9-period EMA of the MACD Line (acts as a trigger).
Histogram: Visualizes the difference between the MACD and Signal lines.
Key interpretations:
Bullish Signal: When the MACD line crosses above the Signal line.
Bearish Signal: When the MACD line crosses below the Signal line.
Divergence: Price and MACD moving opposite directions may indicate trend reversal.
Developed by Gerald Appel in the 1970s, it combines trend and momentum analysis. Traders use it for entries/exits and confirming trends.
Chattes-Grid-Pivot You Can Customize:
Use anchor = pivotHigh if you're in a downtrend
Use math.avg(pivotHigh, pivotLow) to anchor from the midpoint of the range
Let me know if you want to:
Anchor from a fixed price like 1.3700
Automatically switch between pivotHigh/pivotLow based on trend direction
Label each grid line with its price
Chattes-SwingCount Chattes-SwingCount
// This indicator detects swings using a custom ZigZag algorithm and calculates:
// - Average pip movement per swing
// - Standard deviation of pip movement
// - Average number of candles per swing
// - Standard deviation of candle count
//
// The stats are displayed in a compact box at the top-right corner of the chart.
//
// An alert is triggered when a swing's pip size exceeds 1.5× the standard deviation,
// helping identify unusual volatility or significant market moves.
//
// Inputs allow customization of ZigZag detection parameters and swing sample size.
Kippi-VWAPVWAP with Premarket data, when available.
The settings are like the classic VWAP but you can toggle if you want or don't want the premarket data to be included.
I really hope this description is now long enough. Netanya Oleh
Price Change Indicatorit tells what is the current closing price of the day. how much it is down from previous close
Crypto Scalping Strategy [Dubic] - LONG OnlyThis Pine Script strategy snippet adds a temporary, visual label on the chart showing the profit percentage realized at each closed trade exit. When a long position closes, it calculates the profit or loss percentage based on the entry and exit prices, then displays it clearly above the exit candle as a green (profit) or red (loss) label. This helps traders quickly visualize trade outcomes during backtesting or live trading without cluttering the chart with persistent labels.
1m EMA Background ColorEntry Color background indicator where when the 5 ema 1 min timeframe is above the 21 ema 1 min timeframe background is green and when 5 is below the 21 it is red. this can be used for long or short trading
MACD of RSI [TORYS]MACD of RSI — Momentum & Divergence Scanner
Description:
This enhanced oscillator applies MACD logic directly to the Relative Strength Index (RSI) rather than price, giving traders a clearer look at internal momentum and early shifts in trend strength. Now featuring a custom histogram, dual MA types, and RSI-based divergence detection — it’s a complete toolkit for identifying exhaustion, acceleration, and hidden reversal points in real time.
How It Works:
Calculates the MACD line as the difference between a fast and slow moving average of RSI. Adds a Signal Line (MA of the MACD) and plots a Histogram to show momentum acceleration/deceleration. Both RSI MAs and the Signal Line can be toggled between EMA and SMA for custom tuning.
Divergence Detection:
Bullish Divergence : Price makes a lower low while RSI makes a higher low → labeled with a green “D” below the curve.
Bearish Divergence : Price makes a higher high while RSI makes a lower high → labeled with a red “D” above the curve.
Configurable lookback window for tuning sensitivity to pivots, with 4 as the sweet spot.
RSI Pivot Dot Signals:
Plots green dots at RSI oversold pivot lows below 30,
Plots red dots at overbought pivot highs above 70.
Helps detect short-term exhaustion or bounce zones, plotted right on the MACD-RSI curve.
RSI 50 Crosses (Optional):
Optional ▲ and ▼ labels when RSI crosses its 50 midline — useful for momentum trend shifts or pullback confirmation, or to detect consolidation.
Histogram:
Plotted as a column chart showing the distance between MACD and Signal Line.
Colored dynamically:
Bright green : Momentum rising above zero
Light green : Weakening above zero
Bright red : Momentum falling below zero
Light red : Weakening below zero
The zero line serves as the mid-point:
Above = Bullish Bias
Below = Bearish Bias
How to Interpret:
Momentum Confirmation:
Use MACD cross above Signal Line with a rising histogram to confirm breakouts or trend entries.
Histogram shrinking near zero = momentum weakening → caution or reversal.
Exhaustion & Reversals:
Dot signals near RSI extremes + histogram peak can suggest overbought/oversold pressure.
Use divergence labels ("D") to spot early reversal signals before price breaks structure.
Inputs & Settings:
RSI Length
Fast/Slow MA Lengths for MACD (applied to RSI)
Signal Line Length
MA Type: Choose between EMA and SMA for MACD and Signal Line
Pivot Sensitivity for dot markers
Divergence Logic Toggle
Show/hide RSI 50 Crosses
Best For:
Traders who want momentum insight from inside RSI, not price
Scalpers using divergence or exhaustion entries
Swing traders seeking entry confirmation from signal crossovers
Anyone using multi-timeframe confluence with RSI and trend filters
Pro Tips:
Combine this with:
Bollinger Bands breakouts and reversals
VWAP or EMAs to filter entries by trend
Volume spikes or BBW squeezes for volatility confirmation
TTM Scalper Alert to sync structure and momentum