XAutoTrade Alert Builder v1.1Automate Your NinjaTrader Trading with TradingView Alerts
The XAutoTrade Alert Builder is a flexible Pine Script strategy that bridges TradingView alerts with
NinjaTrader automated trading. Design custom entry signals, configure exit strategies, and execute trades
automatically on your NinjaTrader account - all from TradingView charts.
Key Features
📊 Flexible Signal Logic
- Configure buy/sell signals independently
- Compare any two indicators or price sources using crossover, crossunder, greater than, or less than
logic
- Visual buy/sell markers on chart for easy signal verification
🎯 Multiple Exit Methods
1. ATM Strategy - Leverage your existing NinjaTrader ATM templates for advanced order management
2. Source Signals - Exit positions based on opposite entry signals
3. Fixed Levels - Set stop loss and profit targets using ticks or percentage
⚙️ NinjaTrader Integration
- Direct webhook integration with XAutoTrade backend service
- Multi-account support (trade multiple accounts simultaneously)
- Position sizing and max position limits
- Market or limit order types with configurable offset
- Time-in-force options (DAY/GTC)
- Active hours filter (US ET timezone) to control when alerts execute
🔐 Secure & Reliable
- Webhook secret authentication
- Symbol override capability
- Real-time status indicator showing configuration readiness
How It Works
1. Configure Entry Signals - Choose your buy/sell logic by comparing any two data sources (price,
indicators, etc.)
2. Set Exit Strategy - Select ATM templates, signal-based exits, or fixed stop/profit levels
3. Connect to NinjaTrader - Enter your XAutoTrade webhook secret and account details
4. Create Alert - Use the strategy's alert system to send formatted JSON payloads to your XAutoTrade
webhook
5. Trade Futures & Stocks Automatically - TradingView alerts trigger real trades in your NinjaTrader account
Perfect For
- Traders wanting to automate TradingView strategies in NinjaTrader
- Users with existing ATM templates who want TradingView signal automation
- Multi-account traders managing several NinjaTrader accounts
- Anyone seeking a no-code bridge between TradingView and NinjaTrader
Requirements
- Active XAutoTrade account and subscription
- NinjaTrader 8 with XAutoTrade AddOn installed
- TradingView Premium/Pro account (for webhook alerts)
Băng tần và kênh
Log Regression Channel (Dezza Fixed v2)This custom indicator builds a curved Logarithmic Regression Channel designed for long-term Bitcoin and macro asset analysis. It performs a linear regression on the logarithm of price to estimate the market’s fair-value growth curve, then converts that back into price space to form upper and lower deviation bands.
It helps identify where price sits relative to its long-term exponential trend — showing potential overvaluation (upper band) or undervaluation (lower band) zones.
Best used on weekly or monthly charts to visualise market cycles and fair-value reversion. Adjustable inputs let you control lookback length, band width, and midline visibility.
Confirmed Momentum QQQ (RSI/MACD Filter)Gemini and Myself,
How This Targets a Higher Win Rate
The key to the win rate increase is the RSI 20/80 filter.
Long Signal: A long entry is now only taken if the trend is up (SMA cross), the MACD is bullish, and the RSI is not overbought (below 80). By only entering when momentum is not yet exhausted, you increase the chance that the price can travel far enough to hit your 4.0 point Take Profit.
Wider SL: The wider Stop Loss of 2.5 points reduces the chance of being stopped out prematurely by routine market movements (whipsaws), which is the number one killer of win rates in high-frequency trading.
After applying these changes, you will need to run the Strategy Tester again to see the new win rate and the new total number of trades.
Would you like me to help you interpret the new Strategy Tester results once you apply these settings?
Fractional + Heikin-Ashi Candlestick – CF / ABNew model of Candlestick, Tis model constructed on Fractional Calculus mathematical, use two kernel - Caputo-Fabrizio and Atangana-Baleanu.
Daily Midnight Marker (NYC)This indicator automatically plots a vertical line at midnight (00:00) New York time on every trading day.
Each line is drawn in light gray to mark the start of a new day, helping traders visually separate daily sessions.
A weekday label (e.g., Monday, Tuesday, Wednesday...) is displayed to the right of each line, making it easy to identify daily transitions when analyzing intraday price action or reviewing trading sessions.
Perfect for traders who:
Trade based on daily session structure or pre-market setups
Use NY time as a market reference
Prefer a clean and minimal visual day separator
Elliott Wave Expert AdvisorElliott Wave Expert Advisor - Professional Wave Analysis Tool
OVERVIEW
--------
The Elliott Wave Expert Advisor is a comprehensive Pine Script indicator designed for TradingView that automates Elliott Wave analysis and generates high-probability trading signals. Built on Ralph Nelson Elliott's Wave Principle, this indicator identifies impulse wave patterns, validates them against strict Elliott Wave rules, and provides precise entry points with calculated risk management levels.
CORE FUNCTIONALITY
------------------
1. TREND DETECTION
- Dual Moving Average system (Fast/Slow MA)
- MACD confirmation for trend strength
- Automatic trend classification (Uptrend/Downtrend/Sideways)
- Only generates signals aligned with main trend
2. SWING POINT DETECTION
- Automatic pivot high/low identification
- Configurable sensitivity (lookback periods)
- Minimum swing size filtering to reduce noise
- ZigZag visualization connecting swing points
3. WAVE IDENTIFICATION
- 5-wave impulse pattern recognition (1-2-3-4-5)
- 3-wave corrective pattern detection (A-B-C)
- Wave labels displayed on chart
- Color-coded validation status (Blue = Valid, Orange = Pending)
4. ELLIOTT WAVE RULES VALIDATION
Strictly enforces three cardinal rules:
- Rule 1: Wave 2 never retraces more than 100% of Wave 1
- Rule 2: Wave 3 is never the shortest impulse wave
- Rule 3: Wave 4 never overlaps Wave 1 price territory
5. FIBONACCI ANALYSIS
- Automatic Fibonacci retracement calculations (23.6%, 38.2%, 50%, 61.8%, 78.6%)
- Fibonacci extension projections (100%, 161.8%, 261.8%)
- Wave 3 and Wave 5 target projections
- Fibonacci-based Take Profit levels
6. SIGNAL GENERATION
- Entry signals at Wave 2 completion (catch Wave 3)
- Entry signals at Wave 4 completion (catch Wave 5)
- Automatic Stop Loss placement below/above pivot points
- Multiple Take Profit targets (TP1 at 1.618 extension, TP2 at Wave 5 projection)
- Risk/Reward ratio calculation and filtering
- Minimum R:R threshold (default 1.5:1)
7. VISUAL ELEMENTS
- Pivot markers (H/L) showing swing highs and lows
- ZigZag lines connecting swing points
- Wave number labels (1-2-3-4-5) with validation colors
- Entry signal arrows (Green = BUY, Red = SELL)
- Stop Loss lines (Red dashed)
- Take Profit lines (Green dashed and dotted)
- Real-time status dashboard showing:
* Number of pivots detected
* Wave count progress (X/5)
* Pattern validation status
* Market trend direction
* Signal active status
* Helpful tips and guidance
OPTIMAL USAGE
-------------
• Timeframes: H1, H4, D1 (avoid M1-M5 due to noise)
• Markets: Forex majors (EUR/USD, GBP/USD), Gold (XAU/USD), Major Cryptocurrencies
• Market Conditions: Strong trending markets (avoid ranging/sideways conditions)
• Risk Management: Never risk more than 1-2% per trade
• Position Sizing: Based on calculated Stop Loss distance
CONFIGURATION PARAMETERS
------------------------
Trend Detection:
- MA Fast Period (default: 20)
- MA Slow Period (default: 50)
- MACD settings (12/26/9)
Swing Detection:
- Pivot Lookback Left/Right (default: 10/10, reduce to 5/5 for M15)
- Min Swing Size % (default: 0.1%, reduce to 0.05% for M15)
Wave Detection:
- Min Wave Size % (default: 0.5%, reduce to 0.2-0.3% for smaller timeframes)
Risk Management:
- SL Buffer % (default: 0.1%)
- TP1 Fibonacci Ratio (default: 1.618)
- Min Risk/Reward (default: 1.5)
Visualization:
- Toggle visibility for MAs, ZigZag, Wave Labels, Signals, SL/TP
- Customizable colors for all elements
- Optional trend background coloring
IMPORTANT NOTES
---------------
• Elliott Wave analysis is subjective - this indicator implements one specific interpretation
• Works best in trending markets; automatically suppresses signals in sideways conditions
• Signals are NOT repainting after pivot confirmation
• Not a "holy grail" - combine with other analysis and proper risk management
• Requires patience - quality setups are infrequent but high-probability
• Always backtest on historical data before live trading
ELLIOTT WAVE THEORY BACKGROUND
------------------------------
Elliott Wave Theory, developed by Ralph Nelson Elliott in the 1930s, proposes that market prices move in predictable wave patterns driven by investor psychology. An impulse wave consists of five sub-waves (three in the trend direction, two corrections), followed by a three-wave correction. This indicator automates the identification of these patterns and validates them against Elliott's original rules.
DISCLAIMER
----------
This indicator is for educational and informational purposes only. Past performance does not guarantee future results. Always conduct your own analysis and never trade with money you cannot afford to lose. The indicator provides signals based on technical analysis patterns and does not constitute financial advice.
VERSION
-------
v1.0 - Initial Release
Pine Script v5
Created: 2024
SUPPORT
-------
For detailed usage instructions, refer to the included documentation:
- usage_guide.md - Complete user manual with examples
- elliott_rules.md - Elliott Wave theory reference and implementation details
ETH Short-Term VWAP+EMA/RSI (ATR Risk, <1h) (James Logan)ETH Short-Term VWAP + EMA / RSI Strategy (ATR-based Risk Control)
A short-term (< 1 hour) ETH trading system designed for intraday scalps and momentum swings on 5- to 15-minute charts.
It blends trend confirmation (EMA 50 / 200) with intrabar structure (EMA 21 pullback & VWAP filter) and RSI momentum triggers, managing exits dynamically through ATR-based stop, take-profit, and trailing stop targets.
Core logic
• Long when RSI crosses above the threshold within an up-trend (EMA 50 > EMA 200) and price is above VWAP.
• Short when RSI crosses below threshold within a down-trend (EMA 50 < EMA 200) and price is below VWAP.
• Optional pullback confirmation to the 21-EMA for cleaner entries.
• Risk defined by ATR-multiples for stop-loss, take-profit, and an adaptive trailing stop.
• Automatic flat-out exit after a set number of bars (time-based close).
Best use
• 5 min – 15 min ETH/USDT charts (Binance, Bybit, Coinbase, etc.)
• Works with both spot and perpetual data.
• Tune ATR and RSI thresholds per venue; defaults are balanced for 0.05 % per-side fees.
Key parameters
• ATR SL × 1.6 ATR TP × 2.2 ATR Trail × 2.0
• RSI 50 cross | EMA 50/200 trend filter | VWAP confirmation
• Default position sizing = USD-based (e.g. $1 000 per trade).
Notes
• All orders and exits are simulated at bar close; use 1-minute bar magnifier for finer fill modeling.
• No repainting—uses only confirmed bar data.
• Best validated with ≥ 200 trades and profit factor > 1.25 over multi-month backtests.
Hedge Simulation Martingale v1
1. Overview & Strategy Logic
This script implements an automated, multi-position trading strategy that uses a Martingale-inspired approach to manage a series of entries. The core logic is as follows:
Initial Entry: The script enters a trade based on the direction of the previous bar's close. A green bar triggers a Long position; a red bar triggers a Short position.
Profit-Taking: A single, fixed-percentage profit target (Profit Percentage) is set for the entire trade. If reached, all positions are closed for a net profit.
Loss Management (Martingale Logic): If the price moves against the initial position and hits the fixed-percentage stop-loss (Loss Percentage), the script does not exit. Instead, it averages down by adding a new, larger position in the same direction. The size of the new position is determined by multiplying the previous position size by the First Multiplier.
Net Position Management: The script continuously calculates the net average entry price, a new combined profit target, and a new combined stop-loss based on all open positions. The goal is for a single favorable price move to recover all previous losses and hit the profit target.
2. Key Features
Visual Indicators:
Plots the Net Average Entry Price on the chart.
Plots dynamic Profit Target (TP) and Stop-Loss (SL) levels that update as new positions are added.
Displays entry signals (triangles) for the initial Long or Short trade.
Comprehensive Dashboard: A detailed table in the top-right corner shows real-time metrics, including:
Total historical Long/Short volume and PnL.
Current trade's investment, unrealized PnL, and position sizes.
Current position count, direction, and size.
Configurable Parameters:
Profit Percentage: The target profit percentage for the net position.
Loss Percentage: The stop-loss percentage that triggers a new entry.
Initial Position Size: The size of the first position in the series.
First Multiplier: The multiplier applied to the previous position size when averaging down.
Maximum Multiplier: A safety cap (commented out in the code but present) to prevent infinite scaling.
3. Intended Use & Purpose
This script is designed as a position management and tracking tool for traders who are experimenting with or actively using Martingale-style strategies. It is best used to:
Automate the complex calculations of average entry, combined TP/SL, and PnL for multiple entries.
Visually track the status of an ongoing series of positions.
Backtest the viability and risks of such a strategy on historical data.
4. ⚠️ Critical Risk Warning & Disclaimer
THIS STRATEGY CARRIES EXTREME FINANCIAL RISK. USE AT YOUR OWN RISK.
Unlimited Loss Potential: The Martingale strategy is infamous for its potential to generate unlimited losses. By continuously doubling down (or multiplying) on losing positions, a small adverse price move can lead to catastrophic losses that can exceed your account balance.
Margin Calls: The rapidly increasing position size can quickly deplete your margin, leading to a margin call and forced liquidation of all positions at a significant loss.
No Guarantee of Recovery: The assumption that the price will eventually reverse is flawed. A strong, sustained trend can wipe out the entire trading capital.
For Educational/Advanced Use Only: This script is intended for sophisticated traders who fully understand the immense risks involved. It is not a "sure profit" system.
The publisher of this script is not responsible for any financial losses incurred through its use. You are solely responsible for your trading decisions and risk management.
5. How to Use
Apply the Script: Add the script to your chart.
Configure Parameters: Adjust the input parameters according to your risk tolerance and strategy rules. Be extremely cautious with the multiplier and position size.
Monitor the Dashboard: The table will provide all necessary information about the current and historical state of the strategy.
Observe the Levels: Watch the plotted Entry, TP, and SL levels to understand the current market position.
Backtest First: Always test the strategy extensively on historical data before considering it with real capital.
6. Notes
The Maximum Multiplier safety feature is present in the code but is currently commented out. Users are strongly advised to uncomment and set this parameter to act as a final, hard liquidation point.
The script logs key events (trade start, target hit) and export data for further analysis.
This is a complex script and should be thoroughly understood before use.
Daily Midnight Marker (NYC)Daily Midnight Marker (NYC) automatically plots a vertical light-gray line on your chart at midnight New York time (00:00) to visually mark the start of each trading day.
A small label is displayed at the bottom of the line that reads “Day Start”, helping traders quickly identify daily session boundaries.
This indicator is especially useful for:
Futures or forex traders referencing New York session time
Intraday analysts who want to distinguish daily ranges
Backtesting or reviewing overnight/pre-market activity
Features:
Plots at 00:00 NYC time daily
Light gray, clean design to avoid clutter
Optional label under each day start
Ben's BTC Macro Fair Value OscillatorBen's BTC Macro Fair Value Oscillator
Overview
The **BTC Macro Fair Value Oscillator** is a non-crypto fair value framework that uses macro asset relationships (equities, dollar, gold) to estimate Bitcoin's "macro-driven fair value" and identify mean-reversion opportunities.
"Is BTC cheap or expensive right now?" on the 4 Hour Timeframe ONLY
### Key Features
✅ **Macro-driven**: Uses QQQ, DXY, XAUUSD instead of on-chain or crypto metrics
✅ **Dynamic weighting**: Assets weighted by rolling correlation strength
✅ **Mean-reversion signals**: Identifies when BTC is cheap/expensive vs macro
✅ **Validated parameters**: Optimized through 5-year backtest (Sharpe 6.7-9.9)
✅ **Visual transparency**: Live correlation panel, fair value bands, statistics
✅ **Non-repainting**: All calculations use confirmed historical data only
### What This Indicator Does
- Builds a **synthetic macro composite** from traditional assets
- Runs a **rolling regression** to predict BTC price from macro
- Calculates **deviation z-score** (how far BTC is from macro fair value)
- Generates **entry signals** when BTC is extremely cheap vs macro (dev < -2)
- Generates **exit signals** when BTC returns to fair value (dev > 0)
### What This Indicator Is NOT
❌ Not a high-frequency trading system (sparse signals by design)
❌ Not optimized for absolute returns (optimized for Sharpe ratio)
❌ Not suitable as standalone trading system (best as overlay/confirmation)
❌ Not predictive of short-term price movements (mean-reversion timeframe: days to weeks)
---
## Core Concept
### The Premise
Bitcoin doesn't trade in a vacuum. It's influenced by:
- **Risk appetite** (equities: QQQ, SPX)
- **Dollar strength** (DXY - inverse to risk assets)
- **Safe haven flows** (Gold: XAUUSD)
When macro conditions are "good for BTC" (risk-on, weak dollar, strong equities), BTC should trade higher. When macro conditions turn against it, BTC should trade lower.
### The Innovation
Instead of looking at BTC in isolation, this indicator:
1. **Measures how strongly** BTC currently correlates with each macro asset
2. **Builds a weighted composite** of those macro returns (the "D" driver)
3. **Regresses BTC price on D** to estimate "macro fair value"
4. **Tracks the deviation** between actual price and fair value
5. **Signals mean reversion** when deviation becomes extreme
### The Edge
The validated edge comes from:
- **Extreme deviations predict future returns** (dev < -2 → +1.67% over 12 bars)
- **Monotonic relationship** (more negative dev → higher forward returns)
- **Works out-of-sample** (test Sharpe +83-87% better than training)
- **Low correlation with buy & hold** (provides diversification value)
---
## Methodology
### Step 1: Macro Composite Driver D(t)
The indicator builds a weighted composite of macro asset returns:
**Process:**
1. Calculate **log returns** for BTC and each macro reference (QQQ, DXY, XAUUSD)
2. Compute **rolling correlation** between BTC and each reference over `corrLen` bars
3. **Weight each asset** by `|correlation|` if above `minCorrAbs` threshold, else 0
4. **Sign-adjust** weights (+1 for positive corr, -1 for negative) to handle inverse relationships
5. **Z-score normalize** each reference's returns over `fvWindow`
6. **Composite D(t)** = weighted sum of sign-adjusted z-scores
**Formula:**
```
For each reference i:
corr_i = correlation(BTC_returns, ref_i_returns, corrLen)
weight_i = |corr_i| if |corr_i| >= minCorrAbs else 0
sign_i = +1 if corr_i >= 0 else -1
z_i = (ref_i_returns - mean) / std
contrib_i = sign_i * z_i * weight_i
D(t) = sum(contrib_i) / sum(weight_i)
```
**Key Insight:** D(t) represents "how good macro conditions are for BTC right now" in a normalized, correlation-weighted way.
---
### Step 2: Fair Value Regression
Uses rolling linear regression to predict BTC price from D(t):
**Model:**
```
BTC_price(t) = α + β * D(t)
```
**Calculation (Pine Script approach):**
```
corr_CD = correlation(BTC_price, D, fvWindow)
sd_price = stdev(BTC_price, fvWindow)
sd_D = stdev(D, fvWindow)
cov = corr_CD * sd_price * sd_D
var_D = variance(D, fvWindow)
β = cov / var_D
α = mean(BTC_price) - β * mean(D)
fair_value(t) = α + β * D(t)
```
**Result:** A time-varying "macro fair value" line that adapts as correlations change.
---
### Step 3: Deviation Oscillator
Measures how far BTC price has deviated from fair value:
**Calculation:**
```
residual(t) = BTC_price(t) - fair_value(t)
residual_std = stdev(residual, normWindow)
deviation(t) = residual(t) / residual_std
```
**Interpretation:**
- `dev = 0` → BTC at fair value
- `dev = -2` → BTC is 2 standard deviations **cheap** vs macro
- `dev = +2` → BTC is 2 standard deviations **rich** vs macro
---
### Step 4: Signal Generation
**Long Entry:** `dev` crosses below `-2.0` (BTC extremely cheap vs macro)
**Long Exit:** `dev` crosses above `0.0` (BTC returns to fair value)
**No shorting** in default config (risk management choice - crypto volatility)
---
## How It Works
### Visual Components
#### 1. Price Chart (Main Panel)
**Fair Value Line (Orange):**
- The estimated "macro-driven fair value" for BTC
- Calculated from rolling regression on macro composite
**Fair Value Bands:**
- **±1σ** (light): 68% confidence zone
- **±2σ** (medium): 95% confidence zone
- **±3σ** (dark, dots): 99.7% confidence zone
**Entry/Exit Markers:**
- **Green "LONG" label** below bar: Entry signal (dev < -2)
- **Red "EXIT" label** above bar: Exit signal (dev > 0)
#### 2. Deviation Oscillator (Separate Pane)
**Line plot:**
- Shows current deviation z-score
- **Green** when dev < -2 (cheap)
- **Red** when dev > +2 (rich)
- **Gray** when neutral
**Histogram:**
- Visual representation of deviation magnitude
- Green bars = negative deviation (cheap)
- Red bars = positive deviation (rich)
**Threshold lines:**
- **Green dashed at -2.0**: Entry threshold
- **Red dashed at 0.0**: Exit threshold
- **Gray solid at 0**: Fair value line
#### 3. Correlation Panel (Top-Right)
Shows live correlation and weighting for each macro asset:
| Asset | Corr | Weight |
|-------|------|--------|
| QQQ | +0.45 | 0.45 |
| DXY | -0.32 | 0.32 |
| XAUUSD | +0.15 | 0.00 |
| Avg \|Corr\| | 0.31 | 0.77 |
**Reading:**
- **Corr**: Current rolling correlation with BTC (-1 to +1)
- **Weight**: How much this asset contributes to fair value (0 = excluded)
- **Avg |Corr|**: Average correlation strength (should be > 0.2 for reliable signals)
**Colors:**
- Green/Red corr = positive/negative correlation
- White weight = asset included, Gray = excluded (below minCorrAbs)
#### 4. Statistics Label (Bottom-Right)
```
━━━ BTC Macro FV ━━━
Dev: -2.34
Price: $103,192
FV: $110,500
Status: CHEAP ⬇
β: 103.52
```
**Fields:**
- **Dev**: Current deviation z-score
- **Price**: Current BTC close price
- **FV**: Current macro fair value estimate
- **Status**: CHEAP (< -2), RICH (> +2), or FAIR
- **β**: Current regression beta (sensitivity to macro)
---
## Installation & Setup
### TradingView Setup
1. Open TradingView and navigate to any **BTC chart** (BTCUSD, BTCUSDT, etc.)
2. Open **Pine Editor** (bottom panel)
3. Click **"+ New"** → **"Blank indicator"**
4. **Delete** all default code
5. **Copy** the entire Pine Script from `GHPT_optimized.pine`
6. **Paste** into the editor
7. Click **"Save"** and name it "BTC Macro Fair Value Oscillator"
8. Click **"Add to Chart"**
### Recommended Chart Settings
**Timeframe:** 4h (validated timeframe)
**Chart Type:** Candlestick or Heikin Ashi
**Overlay:** Yes (indicator plots on price chart + separate pane)
**Alternative Timeframes:**
- Daily: Works but slower signals
- 1h-2h: May work but not validated
- < 1h: Not recommended (too noisy)
### Symbol Requirements
**Primary:** BTC/USD or BTC/USDT on any exchange
**Macro References:** Automatically fetched
- QQQ (Nasdaq 100 ETF)
- DXY (US Dollar Index)
- XAUUSD (Gold spot)
**Data Requirements:**
- At least **90 bars** of history (warmup period)
- Premium TradingView recommended for full historical data
---
## Reading the Indicator
### Identifying Signals
#### Strong Long Signal (High Conviction)
- ✅ Deviation < -2.0 (extreme undervaluation)
- ✅ Avg |Corr| > 0.3 (strong macro relationships)
- ✅ Price touching or below -2σ band
- ✅ "LONG" label appears below bar
**Interpretation:** BTC is extremely cheap relative to macro conditions. Historical data shows +1.67% average return over next 12 bars (48 hours at 4h timeframe).
#### Moderate Long Signal (Lower Conviction)
- ⚠️ Deviation between -1.5 and -2.0
- ⚠️ Avg |Corr| between 0.2-0.3
- ⚠️ Price approaching -2σ band
**Interpretation:** BTC is cheap but not extreme. Consider as confirmation for other signals.
#### Exit Signal
- 🔴 Deviation crosses above 0 (returns to fair value)
- 🔴 "EXIT" label appears above bar
**Interpretation:** Mean reversion complete. Close long positions.
#### Strong Short/Avoid Signal
- 🔴 Deviation > +2.0 (extreme overvaluation)
- 🔴 Avg |Corr| > 0.3
- 🔴 Price touching or above +2σ band
**Interpretation:** BTC is expensive vs macro. Historical data shows -1.79% average return over next 12 bars. Consider exiting longs or reducing exposure.
### Regime Detection
**Strong Regime (Reliable Signals):**
- Avg |Corr| > 0.3
- Multiple assets weighted > 0
- Fair value line tracking price reasonably well
**Weak Regime (Unreliable Signals):**
- Avg |Corr| < 0.2
- Most weights = 0 (grayed out)
- Fair value line diverging wildly from price
- **Action:** Ignore signals until correlations strengthen
Log Regression Channel (Dezza)This custom indicator builds a curved Logarithmic Regression Channel designed for long-term Bitcoin and macro asset analysis. It performs a linear regression on the logarithm of price to estimate the market’s fair-value growth curve, then converts that back into price space to form upper and lower deviation bands.
It helps identify where price sits relative to its long-term exponential trend — showing potential overvaluation (upper band) or undervaluation (lower band) zones.
Best used on weekly or monthly charts to visualise market cycles and fair-value reversion. Adjustable inputs let you control lookback length, band width, and midline visibility.
OPTION DOMOPTION DOM
This script tell you abot option max pain where dealer needs to reverse and give direction of optio buy and sel plus option dom.
Multi-Reversal + MA50/200 + MACD + BJ (Tilson) Combo//@version=5
indicator(title="Multi-Reversal + MA50/200 + MACD + BJ (Tilson) Combo", overlay=true)
// --- Moving Averages (MA50, MA200) ---
ma_50 = ta.sma(close, 50)
ma_200 = ta.sma(close, 200)
plot(ma_50, color=color.blue, linewidth=1, title="MA50")
plot(ma_200, color=color.red, linewidth=2, title="MA200")
// --- MACD ---
fast_length = input(12, title="MACD Fast")
slow_length = input(26, title="MACD Slow")
signal_length = input(9, title="MACD Signal")
= ta.macd(close, fast_length, slow_length, signal_length)
macd_cross_up = ta.crossover(macdLine, signalLine)
macd_cross_down = ta.crossunder(macdLine, signalLine)
// --- Tilson MA (BJ reversal) ---
tilson_length = input(20, title="Tilson MA Length (BJ reversal)")
tilson_ma = ta.ema(ta.ema(close, tilson_length), tilson_length)
bj_cross_up = close > tilson_ma and close < tilson_ma
bj_cross_down = close < tilson_ma and close > tilson_ma
plot(tilson_ma, color=color.orange, linewidth=2, title="Tilson MA (BJ reversal)")
// --- Đảo chiều tổng hợp ---
bull_reversal = macd_cross_up and bj_cross_up and close > ma_50 and close > ma_200
bear_reversal = macd_cross_down and bj_cross_down and close < ma_50 and close < ma_200
// --- Plot tín hiệu trên chart ---
plotshape(bull_reversal, location=location.belowbar, style=shape.triangleup, size=size.large, color=color.lime, title="Bullish Reversal", text="STRONG UP")
plotshape(bear_reversal, location=location.abovebar, style=shape.triangledown, size=size.large, color=color.red, title="Bearish Reversal", text="STRONG DN")
// --- BJ riêng lẻ ---
plotshape(bj_cross_up, location=location.belowbar, color=color.yellow, style=shape.circle, size=size.tiny, title="BJ Up Only")
plotshape(bj_cross_down, location=location.abovebar, color=color.yellow, style=shape.circle, size=size.tiny, title="BJ Down Only")
// --- Alert conditions ---
alertcondition(bull_reversal, title="Bullish Strong Reversal", message="Buy opportunity: MA bullish + MACD + BJ reversal!")
alertcondition(bear_reversal, title="Bearish Strong Reversal", message="Sell warning: MA bearish + MACD + BJ reversal!")
Multi MA SystemMulti-timeframe moving average indicator with 6 customizable MAs.
Each MA supports 7 types (SMA/EMA/WMA/DEMA/TEMA/HMA/ZLEMA), custom periods, timeframes, colors, and line styles.
Perfect for multi-timeframe analysis and trend identification.
EMA H/L 20-50 Table + RSI - KHALID ALADDIN🧾 Description
EMA H/L 20-50 Table + RSI — by Khalid Aladdin
A clean and minimal indicator designed for traders and analysts who prefer a quick glance at essential EMA values without any extra clutter on the chart.
📊 Features:
Displays precise values of EMA20 (High & Low) and EMA50 (High & Low) in a compact table below the chart.
Automatically updates values based on the current timeframe.
Includes RSI reading for momentum tracking.
Large, clear text with dark-theme friendly colors.
No lines or drawings — only a clean data panel.
✅ Perfect for:
Technical analysts, swing traders, and long-term investors who want an uncluttered view of trend levels and momentum strength.
TMA Dual BandsTMA Dual Bands - Adaptive Channel Indicator with Crossover Signals
TMA Dual Bands represents my interpretation of the classic Triangular Moving Average methodology, specifically designed to identify high-probability trading setups through the interaction of two adaptive channel systems. Unlike traditional channel indicators that rely on static calculations, this tool dynamically adjusts to market volatility while maintaining the smooth, reliable characteristics that make TMA-based systems so effective.
The indicator combines a MAIN channel (slow-moving, representing the broader trend) with a FAST channel (responsive, capturing momentum shifts). When these two systems interact in specific ways, they generate clear trading signals that can be used across multiple timeframes and market conditions.
The Mathematics Behind the Indicator
At its core, this indicator uses a sophisticated approach to calculating Triangular Moving Averages. Rather than using the traditional double Simple Moving Average method, I've implemented a double Weighted Moving Average calculation. This means the TMA is computed by taking a WMA of another WMA, which provides better responsiveness to recent price action while maintaining the smooth, triangular weighting distribution that gives this indicator its name.
The weighted approach significantly reduces lag compared to double-smoothed simple moving averages, allowing the indicator to catch trend changes earlier without sacrificing reliability. This is particularly important for the FAST channel, where responsiveness is crucial for signal generation.
Adaptive Volatility Bands
What makes this indicator truly unique is its adaptive band calculation system. Instead of using a single standard deviation like traditional Bollinger Bands, the indicator maintains separate variance calculations for upward and downward price movements. When price rises above the TMA centerline, the upper band variance increases while the lower band variance decreases proportionally. The opposite occurs when price falls below the centerline.
This asymmetric approach allows the bands to better reflect actual market conditions. During uptrends, the upper band expands to accommodate bullish volatility while the lower band contracts, creating a channel that naturally "leans" in the direction of the trend. The same principle applies in reverse during downtrends.
The full calculation uses a smoothed variance over approximately four times the base period, ensuring that band adjustments are gradual rather than erratic. The multiplier parameter allows you to adjust the sensitivity of the bands to volatility, with higher values creating wider channels that generate fewer but higher-quality signals.
Understanding the Signals
The signal generation mechanism is elegantly simple yet remarkably effective. A bullish signal occurs when the lower FAST band crosses above the lower MAIN band. This crossover indicates that short-term momentum has shifted decisively upward, strong enough to break through the slower-moving baseline channel. These signals typically appear after consolidation periods or healthy pullbacks in uptrends, making them excellent continuation entry points.
Conversely, bearish signals trigger when the upper FAST band crosses below the upper MAIN band. This pattern suggests that upward momentum has exhausted itself and that sellers are beginning to dominate. These signals often appear near resistance levels or at the culmination of extended rallies, providing excellent risk-reward opportunities for counter-trend or trend-reversal trades.
The visual representation enhances signal clarity. The MAIN TMA centerline changes color dynamically based on its slope, displaying green during upward movement and red during downward movement. This gives you instant visual confirmation of the prevailing trend direction. The signal markers themselves appear as diamond shapes positioned just outside the MAIN channel bands, with cyan diamonds indicating buy opportunities below the lower band and blue diamonds marking sell opportunities above the upper band. You could consider taking bull signals only on long trend, and vice versa for the sell signals.
Practical Application
The indicator works across multiple trading approaches and timeframes. For trend-following strategies, the most reliable signals occur when they align with the MAIN TMA color. Taking only green-colored uptrend signals and red-colored downtrend signals significantly improves win rates by ensuring you're always trading with the dominant momentum.
For breakout traders, the most powerful setups occur after periods of compression when the FAST bands squeeze inside the MAIN bands. This compression indicates low volatility and tight consolidation. When a signal finally triggers after such compression, it often leads to explosive moves as the market breaks out of its range.
Mean reversion traders can also benefit from this indicator by taking counter-trend signals when price reaches extreme band levels. However, this approach requires careful risk management and works best in clearly ranging market conditions.
Configuration and Customization
The default parameters have been carefully selected through extensive testing, with the MAIN period set to 133 bars and the FAST period at 19 bars. These values create an effective balance between trend identification and momentum responsiveness. However, the indicator is fully customizable to suit different trading styles and market conditions.
Traders focusing on longer-term positions might increase both periods proportionally, while scalpers and day traders might reduce them. The price type parameter allows you to choose how price is calculated for the TMA, with the weighted option providing the most responsive results. The band multiplier controls how wide the channels expand, with values between 2.5 and 4.0 being most common depending on your preferred signal frequency.
Technical Integrity
A critical feature of this indicator is its complete absence of repainting. All signals are generated and confirmed on closed bars, meaning that once a signal appears in historical data, it will remain exactly where it appeared regardless of subsequent price action. This makes the indicator equally reliable for backtesting historical data and trading live markets, a characteristic that many "magic indicator" systems cannot claim.
The calculation methodology ensures that what you see on your chart is exactly what you would have seen in real-time when that bar closed. There are no retrospective adjustments, no future-peeking calculations, and no algorithmic tricks that make historical performance look better than actual trading results would have been.
Conclusion
TMA Dual Bands offers a sophisticated yet user-friendly approach to technical analysis, combining time-tested TMA methodology with modern adaptive volatility concepts. The dual-channel system provides clear visual representation of market structure while the crossover signals offer objective entry points that remove much of the guesswork from trading decisions.
Whether you're a discretionary trader looking for high-probability setups or a systematic trader seeking reliable signals for automated strategies, this indicator provides the clarity and consistency needed for confident decision-making in dynamic market conditions.
---
**Developed by AlgoAlex81**
*Disclaimer: This indicator is provided for educational and informational purposes only. Past performance does not guarantee future results. Always practice proper risk management and never risk more than you can afford to lose.*
neeson vol proCrypto Exchange Volume Analyzer - Technical Indicator Documentation
Overview
The Crypto Exchange Volume Analyzer is a sophisticated trading indicator designed to monitor and analyze trading volume across major cryptocurrency exchanges in real-time. This tool provides comprehensive market insights by aggregating volume data from multiple sources and detecting abnormal trading activity.
Key Features
Multi-Exchange Data Integration
Real-time volume monitoring from Binance, Coinbase, and Kraken
Combined BTC and ETH trading volume analysis across all supported exchanges
Total trading value calculation in USD equivalents
Market Share Analysis
Dynamic market share calculation for each exchange
Visual representation of exchange dominance
Comparative analysis of trading activity across platforms
Advanced Signal Detection
Statistical anomaly detection using standard deviation methodology
Customizable volume threshold settings (1.0-5.0 std dev)
Color-coded visual alerts for abnormal volume conditions
Comprehensive Data Display
Interactive data table showing volume, value, and market share percentages
Individual cryptocurrency tracking (BTC, ETH, BNB, XRP, ADA, SOL)
Customizable display settings for different trading preferences
Technical Specifications
Input Parameters
Show Volume: Toggle volume column display
Show Data Table: Toggle comprehensive data table
Show Volume Signals: Enable/disable anomaly detection alerts
Volume Threshold: Adjust sensitivity (1.0-5.0 standard deviations)
Time Period: Select analysis timeframe (default: 1D)
Data Sources
Binance: BTCUSDT, ETHUSDT, BNBUSDT, XRPUSDT, ADAUSDT, SOLUSDT
Coinbase: BTCUSD, ETHUSD
Kraken: BTCUSD
Risk Disclaimer
Important Notice
This technical indicator is provided for educational and informational purposes only. Cryptocurrency trading involves substantial risk of loss and is not suitable for every investor. Past performance is not indicative of future results.
Risk Factors to Consider
High volatility in cryptocurrency markets
Potential for significant financial losses
Technical limitations and data latency
Market manipulation risks
Regulatory uncertainties
User Responsibility
Users should:
Conduct their own research before trading
Consult with licensed financial advisors
Understand all risks involved
Only risk capital they can afford to lose
Monitor positions continuously
Copyright and Attribution
Developer Information
Created by: neeson2025
X (Twitter): @neeson1987
Usage Rights
This indicator is provided as educational technology. Commercial use, redistribution, or modification without explicit permission is prohibited. Users acknowledge that the developer bears no responsibility for trading decisions made using this tool.
💎 ProfittoPath – Glass HUD//@version=5
indicator("💎 ProfittoPath – Glass HUD", overlay=true)
// === Inputs ===
entryPrice = input.float(0.0, "Entry Price", step=0.01)
qty = input.float(1.0, "Position Size", step=1.0)
isLong = input.bool(true, "Long Trade?")
offsetY = input.int(60, "Vertical Offset (ticks)", step=1)
showPercent = input.bool(true, "Show % Change")
// === Calculations ===
inTrade = entryPrice > 0
priceDiff = inTrade ? (close - entryPrice) * (isLong ? 1 : -1) : na
plUsd = inTrade ? priceDiff * qty : na
plPercent = inTrade ? (priceDiff / entryPrice) * 100 : na
isProfit = inTrade ? (plUsd >= 0) : false
// === Colors ===
gold = color.rgb(255,215,0)
lossRed = color.rgb(255,90,90)
txtColor = isProfit ? gold : lossRed
bgGlass = color.new(color.rgb(15,15,15),85)
// === Entry Line ===
var line entryLine = na
if barstate.isfirst
entryLine := line.new(bar_index, entryPrice, bar_index, entryPrice, extend=extend.both, color=color.new(gold,40), style=line.style_dotted)
if inTrade
line.set_color(entryLine, color.new(gold,40))
else
line.set_color(entryLine, color.new(color.black,100))
// === Panel Label ===
var label pnlLabel = na
if barstate.isfirst
pnlLabel := label.new(bar_index, na, "", style=label.style_label_center, textcolor=txtColor, color=bgGlass, size=size.large)
// === Update ===
if inTrade
string pnlText = "💎 ProfittoPath Glass HUD "
pnlText += "──────────────────────── "
pnlText += "Trade: " + (isLong ? "LONG 📈" : "SHORT 📉") + " "
pnlText += "Entry: " + str.tostring(entryPrice, format.mintick) + " "
pnlText += "Current: " + str.tostring(close, format.mintick) + " "
pnlText += "P/L: " + (isProfit ? "+" : "") + str.tostring(plUsd, format.mintick) + " USD"
if showPercent
pnlText += " (" + str.tostring(plPercent, "#.##") + "%)"
pnlText += " "
pnlText += "──────────────────────── "
pnlText += "Status: " + (isProfit ? "PROFIT ✅" : "LOSS ❌")
label.set_text(pnlLabel, pnlText)
label.set_x(pnlLabel, bar_index)
label.set_y(pnlLabel, entryPrice + offsetY * syminfo.mintick)
label.set_color(pnlLabel, bgGlass)
label.set_textcolor(pnlLabel, txtColor)
else
label.set_text(pnlLabel, "💎 Set Entry Price ↑")
label.set_x(pnlLabel, bar_index)
label.set_y(pnlLabel, close)
label.set_color(pnlLabel, bgGlass)
label.set_textcolor(pnlLabel, gold)
9:30 AM MarkerThe 9:30 AM Market Open Marker (NYC) indicator automatically plots a vertical line at 9:30 AM New York time, marking the official U.S. stock market open for each trading day.
This visual reference helps traders quickly identify the start of the regular trading session, align intraday strategies, and analyze pre-market and post-market behavior relative to the official open.
Perfect for:
Day traders and scalpers tracking session openings.
Futures traders (e.g., ES, NQ) analyzing volatility around 9:30 AM.
Anyone studying liquidity shifts and structure transitions between pre-market and RTH (Regular Trading Hours).
Features:
Draws a clean vertical line at 9:30 AM NY time for every day.
Optional customizable color and style for clear visual separation.
Works on any timeframe and automatically adjusts for daylight-saving time.
Day of Week (NYC)The Day of Week (NYC) indicator displays the weekday name (Monday, Tuesday, Wednesday, etc.) at the bottom of a separate panel, synchronized with midnight New York time (00:00) for each trading day.
It’s designed to help traders visually distinguish between sessions while keeping the main price chart clean and uncluttered.
The labels remain fixed in their own panel, so they never move in front of candles or interfere with price action.
Perfect for:
Intraday and futures traders who use New York session timing as reference.
Journalers and analysts who review daily session performance.
Anyone who wants clear visual day separators without overlapping chart elements.
Features:
Automatically adapts to NY time (EST/EDT).
Displays weekday names for every new trading day.
Minimalist gray text for a clean, non-distracting look.
6 AM Marker6 AM Marker – Daily Premarket Reference Line
This indicator automatically plots a vertical dotted line at 6:00 AM (local chart time) on every trading day.
It’s designed for traders who track premarket activity and want a clear visual reference of when the early market hours begin.
Features:
Marks 6:00 AM on all trading days automatically
Works on any timeframe
Adjustable timezone (e.g., America/New_York, America/Los_Angeles)
Clean, minimal visual style — perfect for day traders using NQ, ES, or other futures
This simple visual tool helps identify premarket ranges, overnight sessions, and morning setups with precision.
6 AM Marker6 AM Marker – Daily Premarket Reference Line
This indicator automatically plots a vertical dotted line at 6:00 AM (local chart time) on every trading day.
It’s designed for traders who track premarket activity and want a clear visual reference of when the early market hours begin.
Features:
Marks 6:00 AM on all trading days automatically
Works on any timeframe
Adjustable timezone (e.g., America/New_York, America/Los_Angeles)
Clean, minimal visual style — perfect for day traders using NQ, ES, or other futures
This simple visual tool helps identify premarket ranges, overnight sessions, and morning setups with precision.
Trendy Bands + Reversal SignalsTrendy Bands + Reversal Signals
This is a versatile and powerful TradingView indicator that combines a dual Bollinger Bands system with momentum-based reversal signals. It's designed to help traders identify the prevailing trend, potential volatility expansions/contractions, and key reversal points in the market.
Core Concept: The indicator uses two sets of Bollinger Bands with different standard deviation settings to create a "band within a band" structure. This visual setup makes it easier to gauge trend strength and spot potential breakouts or breakdowns. Additionally, it calculates a custom momentum oscillator to generate early warnings for potential trend reversals.






















