OPEN-SOURCE SCRIPT
AetherEdge - Intermarket Correlation

🖊️ Overview
Correlation tables are static; AE-CORR learns which markets actually drive this symbol. Alongside rolling correlation and beta of the chart symbol versus six reference markets (BTC / ETH / crypto cap / DXY / Gold / S&P 500, etc.), an online regression learns each market's predictive weight, producing a next-bar return forecast (with a conformal-calibrated band) and an intermarket directional bias.
🔶 Key Features
Learned driver analysis — learns which markets drive the next move (identifies the dominant driver)
Rolling correlation + beta — live coupling and sensitivity per reference
1-bar lead-lag — how much a reference's prior move predicts the next bar (signed)
Predicted next-bar return — with a ± conformal band for honest uncertainty
Intermarket bias — long/short/flat from the structure
Coupling — overall co-movement strength (a risk-on/off gauge)
Chart triangles + alerts on bias flips; bar-close updates — no repaint
🧠 Technical Architecture
Stats: rolling correlation (ta.correlation) and beta = correlation × (chart σ / ref σ) (contemporaneous coupling and sensitivity).
ML (online linear regression): features are six standardized reference returns plus the chart's own momentum, trained on lag-1 (weights that predict the next bar, updated without lookahead). The learned weights expose each market's drive and sign; the largest is shown as the dominant driver. The live prediction estimates the next-bar return (%) from current returns.
Calibration (split-conformal): the (1-α) quantile of realized residuals forms the band, so predicted ± band matches the target coverage empirically.
Honest scope: linear regression over standard features + nonparametric conformal calibration (no RL). Not deep learning, not a guarantee.
⚙️ Recommended Settings & Tuning Guide (crypto 15m–4H)
Key parameters: reference timeframe, correlation length, standardization length, learning rate, band significance (1-α), calibration window, bias threshold (× vol), the six references.
Correlation length ≈ 50 is standard; shorter tracks recent coupling, longer is steadier
References are fully swappable (for crypto, BTC/ETH/TOTAL/DXY/GOLD/SPX are classics); blank = skipped
Bias threshold = how many multiples of normal vol the prediction must exceed (≈ 0.5)
Pin references to a higher timeframe for a macro-structure bias
⚠️ The number of referenced markets (security calls) is capped
💡 How to Use in Practice
Check the dominant driver and watch that market as a lead
Use the sign of correlation to design hedges/diversification (negative-corr markets as insurance)
Use predicted next ± band for short-term expectation and risk
Use the bias triangles as an intermarket filter on single-symbol signals
Combine with AE-VOL (volatility) or AE-BPE (breakout probability) to layer driver × level
⚠️ Important Notes
Needs a learning period (warmup); weights re-learn on reference/timeframe change
Correlation is not causation (coupling can break down)
The next-bar forecast is short-horizon and probabilistic — large shocks will miss
Probability, not a guarantee — always do your own due diligence and use risk management
🚨 Disclaimer
This indicator is for educational and informational purposes only and is not financial advice or a recommendation to buy or sell. No method guarantees future profits; past performance does not indicate future results, and trading carries the risk of loss. All decisions are your own — use proper validation and disciplined risk management.
Correlation tables are static; AE-CORR learns which markets actually drive this symbol. Alongside rolling correlation and beta of the chart symbol versus six reference markets (BTC / ETH / crypto cap / DXY / Gold / S&P 500, etc.), an online regression learns each market's predictive weight, producing a next-bar return forecast (with a conformal-calibrated band) and an intermarket directional bias.
🔶 Key Features
Learned driver analysis — learns which markets drive the next move (identifies the dominant driver)
Rolling correlation + beta — live coupling and sensitivity per reference
1-bar lead-lag — how much a reference's prior move predicts the next bar (signed)
Predicted next-bar return — with a ± conformal band for honest uncertainty
Intermarket bias — long/short/flat from the structure
Coupling — overall co-movement strength (a risk-on/off gauge)
Chart triangles + alerts on bias flips; bar-close updates — no repaint
🧠 Technical Architecture
Stats: rolling correlation (ta.correlation) and beta = correlation × (chart σ / ref σ) (contemporaneous coupling and sensitivity).
ML (online linear regression): features are six standardized reference returns plus the chart's own momentum, trained on lag-1 (weights that predict the next bar, updated without lookahead). The learned weights expose each market's drive and sign; the largest is shown as the dominant driver. The live prediction estimates the next-bar return (%) from current returns.
Calibration (split-conformal): the (1-α) quantile of realized residuals forms the band, so predicted ± band matches the target coverage empirically.
Honest scope: linear regression over standard features + nonparametric conformal calibration (no RL). Not deep learning, not a guarantee.
⚙️ Recommended Settings & Tuning Guide (crypto 15m–4H)
Key parameters: reference timeframe, correlation length, standardization length, learning rate, band significance (1-α), calibration window, bias threshold (× vol), the six references.
Correlation length ≈ 50 is standard; shorter tracks recent coupling, longer is steadier
References are fully swappable (for crypto, BTC/ETH/TOTAL/DXY/GOLD/SPX are classics); blank = skipped
Bias threshold = how many multiples of normal vol the prediction must exceed (≈ 0.5)
Pin references to a higher timeframe for a macro-structure bias
⚠️ The number of referenced markets (security calls) is capped
💡 How to Use in Practice
Check the dominant driver and watch that market as a lead
Use the sign of correlation to design hedges/diversification (negative-corr markets as insurance)
Use predicted next ± band for short-term expectation and risk
Use the bias triangles as an intermarket filter on single-symbol signals
Combine with AE-VOL (volatility) or AE-BPE (breakout probability) to layer driver × level
⚠️ Important Notes
Needs a learning period (warmup); weights re-learn on reference/timeframe change
Correlation is not causation (coupling can break down)
The next-bar forecast is short-horizon and probabilistic — large shocks will miss
Probability, not a guarantee — always do your own due diligence and use risk management
🚨 Disclaimer
This indicator is for educational and informational purposes only and is not financial advice or a recommendation to buy or sell. No method guarantees future profits; past performance does not indicate future results, and trading carries the risk of loss. All decisions are your own — use proper validation and disciplined risk management.
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。
開源腳本
秉持TradingView一貫精神,這個腳本的創作者將其設為開源,以便交易者檢視並驗證其功能。向作者致敬!您可以免費使用此腳本,但請注意,重新發佈代碼需遵守我們的社群規範。
免責聲明
這些資訊和出版物並非旨在提供,也不構成TradingView提供或認可的任何形式的財務、投資、交易或其他類型的建議或推薦。請閱讀使用條款以了解更多資訊。