S&D DirectionThis indicator displays the most recent candle close direction for up to five custom timeframes, as selected in the settings. For each chosen timeframe, it shows whether the last confirmed candle close was bullish (close above the previous high) or bearish (close below the previous low). The indicator labels each timeframe in the top right corner, using green text for bullish closes and red for bearish closes. The displayed timeframes can be customized, and the direction (long/short) is clearly shown after each label.
Indicators and strategies
S&R Zones MTF (TechnoBlooms)S&R Zones MTF – Multi-Timeframe Support & Resistance Boxes
🔍 Overview
S&R Zones MTF is a professional-grade yet beginner-friendly indicator that dynamically plots Support & Resistance zones across multiple timeframes, helping traders recognize high-probability reversal areas, entry confirmations, and price reaction points.
This tool visualizes structured zones as colored boxes, allowing both new and experienced traders to analyze multi-timeframe confluence with ease and clarity.
🧠 What Is This Indicator?
S&R Zones MTF automatically detects the most significant support and resistance levels from up to four custom timeframes, using a configurable lookback period. These zones are displayed as colored horizontal boxes directly on the chart, making it easy to:
Spot where price has historically reacted
Identify potential reversal or breakout zones
Confirm entries with institutional-style precision
🛠️ Key Features
✅ Multi-Timeframe Zone Detection (up to 4 timeframes)
📦 Auto Plotted Boxes for Support (Blue) & Resistance (Pink)
🧱 Dynamic Height based on average price range or fixed input
🏷️ Timeframe Labels to instantly identify zone origin
🎛️ Customizable inputs: Lookback length, box color, height style
🔁 Real-time updates as price structure changes
🎓 Educational & Easy to Use
Whether you’re a new trader learning about price structure, or a professional applying institutional concepts, this tool offers an educational layout to understand:
How price respects historic zones
Why multi-timeframe zones offer stronger confluence
How to use zones for entry, exit, or risk placement
📈 How to Use (Multi-Timeframe Strategy)
Select Your Timeframes – Customize up to 4 higher timeframes (e.g., 1m, 5m, 15m, 1h).
Observe Overlapping Zones – When multiple timeframes agree, those zones are more significant.
Entry Confirmation – Wait for price to reach a zone, then look for reversal patterns (engulfing candle, pin bar, etc.)
Combine with Other Tools – Use alongside indicators like RSI, MACD, or Order Blocks for added confidence.
💡 Pro Tips
Zones from higher timeframes (1H, 4H) are often more powerful and reliable.
Confluence matters: If a 15m support zone aligns with a 1H support zone — that's a high-probability reaction area.
Use break-and-retest strategies with zone rejections for sniper entries.
Enable "Auto Height" for a more adaptive, volatility-based zone display.
🌟 Summary
S&R Zones MTF blends precision, clarity, and professional analysis into a visual structure that’s easy to understand. Whether you're learning support & resistance or optimizing your MTF edge — this tool will bring clarity to your charts and confidence to your trades.
RSI+BOLLINGER (LONG & SHORT)This indicator combines two of the most popular tools in technical analysis, the Relative Strength Index (RSI) and Bollinger Bands (BB), to generate both long (BUY) and short (SELL) trading signals.
Strategy:
Entries (Buy/Short): Entry signals are based on the RSI.
A BUY is suggested when the RSI crosses above an oversold level (default: 29), indicating a possible upward reversal.
A SHORT is suggested when the RSI crosses below an overbought level (default: 71), indicating a possible downward reversal.
Exits (Position Closure): Exit signals are based on Bollinger Bands.
A long position is closed when the price crosses below the upper Bollinger Band.
A short position is closed when the price crosses above the lower Bollinger Band.
Key Features:
Cascade Filter: Includes a smart filter that prevents opening new consecutive trades if the price hasn't moved significantly in favor of a new entry, optimizing signal quality.
Automation Alerts: Generates detailed alerts in JSON format for each event (buy, sell, close), designed for easy integration with trading bots and automated systems via webhooks.
Fully Configurable: All parameters of the RSI, Bollinger Bands, and strategy filters can be adjusted from the indicator’s settings menu.
Multi-Timeframe High/Low LinesMulti-Timeframe High/Low Lines
Track and visualize high/low levels from multiple timeframes with automatic interaction detection and alerts.
Features:
Displays horizontal lines for highs and lows from Daily, Weekly, Monthly, Quarterly, and Yearly timeframes
Lines extend to the right until price interacts with them
Automatic interaction detection - lines stop extending when touched
Customizable colors for each timeframe and level type
Configurable line width and style (solid, dashed, dotted)
Built-in alerts for level interactions
Performance optimized for smooth operation
Works with traditional markets (futures, stocks) and crypto
How It Works:
Detects new candles on higher timeframes (Daily, Weekly, Monthly, Quarterly, Yearly)
Creates horizontal lines at the high and low of each new timeframe candle
Lines are drawn from the exact time/bar where the high/low occurred
Lines extend to the right until price touches the level
When a level is touched, the line stops extending and is marked as "hit"
Alerts can be configured to notify when levels are touched
Settings:
Timeframe Settings: Enable/disable individual timeframes
Visual Settings: Line width, style, and maximum number of levels
Colors: Custom colors for each timeframe's highs and lows
Alert Settings: Enable alerts for high/low level touches
Use Cases:
Identify key support and resistance levels from higher timeframes
Track when price interacts with significant levels
Use as part of a multi-timeframe analysis strategy
Set up alerts for level breaks or bounces
Combine with other indicators for entry/exit signals
Compatibility:
Works on all timeframes (1m to monthly)
Compatible with traditional markets (futures, stocks, forex)
Optimized for crypto markets
Handles market gaps and session resets properly
This indicator automatically manages line lifecycle, removing old lines and limiting total count for optimal performance.
HTF CandlesFull credit to cdikici71 - this is a stripped down version of cd_sweep&cisd_Cx to provide a clean higher timeframe (HTF) candle overlay. Choose colors for candles & font along with timeframe to overlay the HTF on any other timeframe.
Simple and Clean!
Crypto DanR 1.4.2 PC-Roye Edition📜 Crypto DanR 1.4.2 — PC Roye Edition (Open Source)
This indicator combines Smart Money Concepts (SMC), Liquidity Analysis, and Trend Filtering to provide traders with a high-quality tool for intraday and swing trading on assets like XRP/USDT.
✅ What This Script Does
Crypto DanR 1.4.2 integrates the following advanced features:
Break of Structure (BOS) & Change of Character (CHoCH):
Detects key shifts in market structure
Helps confirm trend direction and reversal points
Fair Value Gaps (FVG):
Displays unmitigated liquidity voids using a style inspired by LuxAlgo
Highlights potential retracement zones where smart money may re-enter
Equal Highs / Equal Lows (EQH/EQL):
Marks liquidity zones that institutions often target before reversals
Order Blocks (OB):
Identifies potential institutional demand/supply zones
Option to filter by wick, body, or mitigation logic
Fibonacci Volatility Bands (based on BigBeluga’s logic):
Detects potential price extremes using Fib extensions on volatility
10 Moving Averages in One (inspired by hiimannshu's script):
Supports 10 custom MAs (SMA, EMA, RMA, HMA, VWMA, etc.) with adjustable source and timeframe
Ideal for trend filtering or dynamic support/resistance
Vector Candles (TradersReality / PVSRA):
Color-coded candles showing real-time volume pressure and trend bias
Visual Trade Plan:
Optional overlay for entry, stop-loss, and take-profit planning
Displays risk-to-reward ratio and potential % gain/loss live
🧠 How It Works
The script uses a price-action-first approach, built around concepts from Smart Money Theory. CHoCH and BOS detect structural shifts, while FVGs and OBs help forecast likely reaction zones. The multiple moving averages act as a trend filter to avoid entering against momentum.
This combination allows traders to:
Enter on mitigations or breakouts
Set stops outside liquidity zones
Manage trades visually with dynamic risk/reward levels
📊 Best Use Cases
15m or 1h scalping (ideal)
Swing trading on 4h
Works well on crypto, FX, and indices
🙏 Credits
TradersReality for PVSRA logic via public library
LuxAlgo for FVG inspiration
hiimannshu for 10-in-1 MA logic
BigBeluga for Fibonacci Bands methodology
All reused logic is significantly modified and part of a broader framework.
📌 Notes
Script is open-source to promote transparency and collaboration
Please do not copy-paste and republish without adding meaningful improvements
Feedback and suggestions welcome!
Larry Williams's Market Structure
Here is a Pine script based on Larry Williams' market structure model.
Note: When processing real-time ticks, heavy calculations can cause script errors. To prevent this, please adjust the script's data range accordingly.
As I'm not an expert in Pine Script, there may be some imperfections. Your understanding is appreciated.
I have great admiration for the wisdom of Larry Williams.
May the trend be with you.
VOLUME Simple [Titans_Invest]VOLUME Simple
A streamlined volume analysis tool crafted for simplicity and smart signal detection.
Although simple in appearance, this indicator brings intelligent volume-based entries through configurable logic. Its design emphasizes clean and effective interpretation of volume signals.
⯁ WHAT IS THE VOLUME INDICATOR❓
The Volume indicator is a fundamental technical analysis tool that measures the number of shares or contracts traded in a security or market during a given period. It helps traders and investors understand the strength or weakness of a price movement, confirm trends, and predict potential reversals. Volume is typically displayed as a histogram below a price chart, with each bar representing the volume traded during a specific time interval.
⯁ HOW TO USE THE VOLUME❓
The Volume indicator can be used in several ways to enhance trading decisions:
• Trend Confirmation: High volume during a price move confirms the strength of that trend, while low volume can indicate a weak or unsustainable trend.
• Breakouts: A price breakout from a pattern or range accompanied by high volume is more likely to be valid and sustainable.
• Divergence: When the price moves in one direction and volume moves in the opposite direction, it can signal a potential reversal.
• Overbought/Oversold Conditions: Extreme volume levels can sometimes indicate that an asset is overbought or oversold, though this is less straightforward than with oscillators like the RSI.
⯁ ENTRY CONDITIONS
The conditions below are fully flexible and allow for complete customization of the signal.
______________________________________________________
🔹 CONDITIONS TO BUY 📈
______________________________________________________
▪︎ Signal Validity: The signal will remain valid for X bars .
🔹 volume > volume_MA * Trigger Signal (close > open)
🔹 volume > volume_MA * Trigger Signal (Keep State)
______________________________________________________
______________________________________________________
🔸 CONDITIONS TO SELL 📉
______________________________________________________
▪︎ Signal Validity: The signal will remain valid for X bars .
🔸 volume > volume_MA * Trigger Signal (close > open)
🔸 volume > volume_MA * Trigger Signal (Keep State)
______________________________________________________
______________________________________________________
🤖 AUTOMATION 🤖
• You can automate the BUY and SELL signals of this indicator.
______________________________________________________
______________________________________________________
⯁ UNIQUE FEATURES
______________________________________________________
Signal Validity: The signal will remain valid for X bars
Condition Table: BUY/SELL
Condition Labels: BUY/SELL
Plot Labels in the Graph Above: BUY/SELL
Automate and Monitor Signals/Alerts: BUY/SELL
Signal Validity: The signal will remain valid for X bars
Table of Conditions: BUY/SELL
Conditions Label: BUY/SELL
Plot Labels in the graph above: BUY/SELL
Automate & Monitor Signals/Alerts: BUY/SELL
______________________________________________________
📜 SCRIPT : VOLUME Simple
🎴 Art by : @Titans_Invest & @DiFlip
👨💻 Dev by : @Titans_Invest & @DiFlip
🎑 Titans Invest — The Wizards Without Gloves 🧤
✨ Enjoy!
______________________________________________________
o Mission 🗺
• Inspire Traders to manifest Magic in the Market.
o Vision 𐓏
• To elevate collective Energy 𐓷𐓏
EMA 8/21/50 + VWAP Crossover Alert IndicatorOverview of the Indicator
This is a custom Pine Script v5 indicator for TradingView titled "EMA 8/21/50 + VWAP Crossover Alert Indicator" (short title: "EMA+VWAP Cross Alert"). It's designed as an overlay indicator, meaning it plots directly on your price chart rather than in a separate pane. The primary purpose is to detect and alert on crossovers between the 8-period Exponential Moving Average (EMA) and the 21-period EMA, which can signal potential bullish or bearish momentum shifts. These are classic short-term trend reversal or continuation signals often used in trading strategies like momentum or swing trading.
To enhance analysis, it also includes:
A 50-period EMA for medium-term trend context (e.g., to confirm if the overall trend aligns with the crossover).
A Volume Weighted Average Price (VWAP) line, which provides a benchmark for the average price weighted by volume, useful for identifying intraday value areas or fair price levels.
The indicator works across all timeframes (e.g., Daily, 4H, 1H, 15M, 5M, 3M) because the calculations are based on the chart's current bars and adapt to volatility and data resolution. It's not a trading strategy (no entry/exit logic or backtesting), but an alert tool—signals are visual and can trigger notifications in TradingView. Always combine it with risk management, as crossovers can produce false signals in ranging or choppy markets.
Stop Order Entry with Filters and Line📌 名称: Stop Order Entry with Filters (挂单入场辅助工具)
🧠 作者: Kuixi Zhu
🛠️ 功能简介:
本指标用于识别高质量的 Bull/Bear bar,并在其上方(或下方)自动绘制挂单入场线,帮助你基于 Price Action 策略设置 **buy stop / sell stop** 挂单。
✅ 特性:
- Bull bar:收盘靠近 high,且 bar 波动大于平均(ABR) → 在 high+1tick 画绿线(buy stop)
- Bear bar:收盘靠近 low,且 bar 波动大于平均 → 在 low-1tick 画红线(sell stop)
- 支持自定义线条长度、ABR周期、强度过滤标准
🔍 核心逻辑:
- `(close - low) / (high - low)` 衡量收盘靠近 high 的程度
- `barRange > avg(barRange)` 控制有效波动性
- 使用 `line.new` 动态画出可视化入场价格
📊 应用场景:
- 趋势交易中的顺势挂单策略
- price action 高质量 bar 的识别辅助
- 多头突破、空头反转结构的自动提示
⚙️ 参数可调:
- 最低收盘位置比例(default: 0.9)
- 最小 bar 波动倍数(相对 ABR)
- 横线绘制长度(default: 5 bars)
---
Prev Candle Quarters (MTF) – % + PriceThis TradingView indicator visualizes quarter levels (25%, 50%, 75%, 100%) of the previous candle body from a user-selected higher timeframe, helping traders identify key reaction zones within a candle’s structure.
ulti-Timeframe Input: Choose between 15m, 1H, or 2H candles for your measurement basis.
Body-Based Calculation: Measures from open to close of the previous candle (not wick-to-wick), reflecting where price actually closed.
Precise Quarter Levels: Automatically draws horizontal lines at 25%, 50%, 75%, and 100% of the candle body.
Custom Toggles: Enable or disable each individual level via checkboxes.
Price + % Labels: Each level includes a clean label showing the exact price and corresponding percentage.
🧠 Rogue BTC Dominance + BTC Price MonitorLiquidity never lies.
When whales are done pumping, they exit before price tanks, often during sideways chop or fake strength.
So we build a tracker that detects:
Volume drop during uptrend (distribution phase)
Exchange inflows of coins
Rising USDT.D while price holds → stealth exit
Divergence between price & on-chain flows
👁️ Quick Use Case: BTC/USDT with USDT.D Overlay
If you see this pattern:
BTC sideways or slow uptrend
Volume declining
USDT.D rising
BTC.D holding flat
→ Liquidity Exit Detected.
Smart money is exiting quietly, waiting for retail to hold the bag.
GLOBEX BOX v1.0All credit to the creator and teacher of this strategy, @RS.
The "GOBEX BOX v1.0" indicator draws customizable horizontal rectangles (with optional midlines and labels) around specific opening candles in the EST timezone ("America/New_York").
It highlights:
The 09:30–09:31 EST 1-minute candle high/low for Monday through Friday.
The 18:00–18:05 EST 5-minute candle high/low for Sunday through Thursday.
Various customizable features are in the indicator settings.
Happy trading!
MA Cross With Buy and SellThe Enhanced MA Cross indicator helps traders identify changes in market trends by tracking two moving averages: one short-term and one long-term. When the short-term average crosses above the long-term one, it suggests that momentum is shifting upward, often signaling a buying opportunity. Conversely, when the short-term average drops below the long-term, it may indicate that selling pressure is increasing, signaling a possible exit or short position.
This indicator is particularly useful in trending markets—places where prices are clearly moving up or down—like during strong moves in stocks, crypto, forex, or commodities. It gives you visual buy and sell markers right on the chart, and you can even enable alerts so you don't miss key moments.
However, it's not a great tool for sideways or ranging markets, where prices bounce around without direction. In those situations, the crossover signals can become noisy and less reliable.
Overall, it's a simple, beginner-friendly tool for spotting trend shifts and making more confident trade entries and exits. If needed, we can make it even smarter by combining it with other indicators to filter out bad signals.
VIX‑Based σ‑BandsThis Pine Script v5 indicator builds a volatility‑based envelope around yesterday’s close using CBOE’s volatility indices. It dynamically pulls VIX, VXN, VXD or RVX—depending on whether you’re charting ES, NQ, YM or RTY—and converts annualized volatility into dollar‑move bands at ±¼ σ, ±½ σ, ±1 σ, and ±2 σ. Optional “mid‑lines” fill in the gaps between each band for even finer precision.
Thors Ghost Candles Thors Ghost Candles (TGC)
A volume-based indicator that visualizes volume through dynamic candle transparency.
Candles fade or intensify based on relative volume strength, creating "ghost" effects for
low-volume periods and highlighting significant volume spikes.
Key Features:
- Candle opacity adjusts based on volume Z-score (standard deviations from mean)
- High volume candles appear solid, while low volume candles become transparent
- Includes volume moving average overlay
- Built-in alerts for extreme volume conditions
- Customizable colors and option to completely hide low-volume bars
Perfect for identifying genuine breakouts, spotting volume divergences, and filtering out
low-conviction price movements. The ghost effect helps traders focus on price action backed
by significant volume.
Clarix 5m Scalping Breakout StrategyPurpose
A 5-minute scalping breakout strategy designed to capture fast 3-5 pip moves, using premium/discount zone filters and market bias conditions.
How It Works
The script monitors price action in 5-minute intervals, forming a 15-minute high and low range by tracking the highs and lows of the first 3 consecutive 5-minute candles starting from a custom time. In the next 3 candles, it waits for a breakout above the 15m high or below the 15m low while confirming market bias using custom equilibrium zones.
Buy signals trigger when price breaks the 15m high while in a discount zone
Sell signals trigger when price breaks the 15m low while in a premium zone
The strategy simulates trades with fixed 3-5 pip take profit and stop loss values (configurable). All trades are recorded in a backtest table with live trade results and an automatically updated win rate.
Features
Designed exclusively for the 5-minute timeframe
Custom 15-minute high/low breakout logic
Premium, Discount, and Equilibrium zone display
Built-in backtest tracker with live trade results, statistics, and win rate
Customizable start time, take profit, and stop loss settings
Real-time alerts on breakout signals
Visual markers for trade entries and failed trades
Consistent win rate exceeding 90–95% on average when following market conditions
Usage Tips
Use strictly on 5-minute charts for accurate signal performance. Avoid during high-impact news releases.
Important: Once a trade is opened, manually set your take profit at +3 to +5 pips immediately to secure the move, as these quick scalps often hit the target within a single candle. This prevents missed exits during rapid price action.
Long-Indicator + Exit-AlertThis simple and intuitive trading indicator is tailored for beginners and generates a clear long entry signal when three specific conditions are met:
- The stock price is above the EMA200, signaling a prevailing uptrend.
- The MACD histogram switches from negative to positive, indicating a bullish momentum shift.
- The Volume Oscillator is positive (above the zero line), suggesting rising trading volume and market interest.
Alert: When all three criteria are fulfilled, an alert is triggered for a potential long position.
- Take Profit (TP): The position is exited with profit when the price reaches the upper boundary of the Donchian Channel.
- Stop Loss (SL): The position is closed to limit losses if the price hits the lower boundary of the Donchian Channel.
WT + Stoch RSI Reversal Combo📊MR.Z RSI : WT + Stochastic RSI Reversal Combo
This custom indicator combines WaveTrend oscillator and Stochastic RSI to detect high-confidence market reversal points, filtering signals so they only appear when both indicators align.
🔍 Core Components:
✅ WaveTrend Oscillator
Based on smoothed deviation from EMA (similar to TCI logic)
Plots:
WT1 (main line)
WT2 (signal line = SMA of WT1)
Uses overbought/oversold thresholds (default: ±53) to filter signals
✅ Stochastic RSI
Momentum oscillator based on RSI's stochastic value
Plots:
%K: smoothed Stoch of RSI
%D: smoothed version of %K
Adjustable oversold/overbought thresholds (default: 20/80)
🔁 Combined Reversal Signal Logic:
🔼 Buy Signal
WT1 crosses above WT2 below WT oversold level (e.g., -53)
%K crosses above %D below Stoch RSI oversold level (e.g., 20)
🔽 Sell Signal
WT1 crosses below WT2 above WT overbought level (e.g., 53)
%K crosses below %D above Stoch RSI overbought level (e.g., 80)
🔔 Signals are only plotted and alerted if both conditions are true.
📌 Features:
Toggle on/off:
WaveTrend lines and histogram
Stochastic RSI
Combined Buy/Sell signals
Horizontal reference lines (±100, OB/OS)
Fully customizable smoothing lengths and thresholds
Signal plots:
✅ Green up-triangle = Combo Buy
✅ Red down-triangle = Combo Sell
Optional: Circle/cross markers for WT-only and Stoch-only signals
🔔 Built-in alerts for Buy/Sell signals
📈 Use Cases:
Reversal Trading: Wait for both indicators to confirm momentum shift
Entry Filter: Use in combination with trend indicators (like EMA)
Scalping or Swing: Works on intraday and higher timeframes
SMC XAU/USD Pro✅ Structure filter: Only BUY if the price is above the last bullish BOS, and SELL if it is below the last bearish BOS.
✅ Significant candle body: At least 40% of the range to avoid weak signals.
✅ Boxes limited to 3 per type (old ones automatically cleared).
✅ Visual display of Take Profit and Stop Loss with green and red dashed lines.
✅ Clear BUY/SELL signals with visible labels.
Reversal Signal avec TICK + RSIThis indicator is a potential reversal indicator for SCALPING, don't use it for swing. It's base on TICK and on an overbrought/oversold condition of the RSI. You can play with the setting, typicaly I like my TICK to be over reacting an 800/-800 and my rsi over 20 and 80, but it give not enough signal. So I set the TICK signal at 651/-651 and the RSI at 25/75. This indicator is made for SP500 and Nasdaq, so SPY/QQQ/SPX/ES/NQ should work well. It's the first version of it, so maybe I'll add so more data to it to increase signal and lower false one. For now I've test it on live market yet(26/7/25).
The RSI is Fast(5 period), I like to use it on the 1 or 5 min chart.
Please not that it only work during 9h30am to 4pm EST.(Because of the TICK)
Feel free to try and even comment. Don't be harsh on me, it's my first try!
(Sorry for my 'english' it's not my first language)
FAUCON
Supertrend with ADX & MTF MA Filter# **Supertrend with ADX & MTF MA Filter - Comprehensive Explanation**
---
## **1. Purpose of This Indicator**
This indicator combines three powerful technical analysis tools to create a robust trading system:
✅ **Supertrend** (Trend-following)
✅ **ADX Filter** (Trend strength confirmation)
✅ **MTF MA Filter** (Multi-timeframe trend direction confirmation)
**Primary Goals:**
✔ **Identify high-probability trend reversals** with confirmation from multiple indicators
✔ **Filter out weak trends** using ADX (Average Directional Index)
✔ **Add higher timeframe context** with MTF (Multi-TimeFrame) Moving Average
✔ **Reduce false signals** by requiring confluence between all three components
---
## **2. Core Logic & Components**
### **A. Supertrend (Base Indicator)**
- **Calculation:**
```pine
up = hl2 - (Multiplier * ATR(Periods))
dn = hl2 + (Multiplier * ATR(Periods))
```
- **Bullish trend** when price > `up` (green line)
- **Bearish trend** when price < `dn` (red line)
- **Why Supertrend?**
- Simple yet effective trend-following system
- Adapts to volatility via ATR (Average True Range)
---
### **B. ADX Filter (Trend Strength Confirmation)**
- **ADX Calculation:**
```pine
= calcADX(adxLength, adxSmoothing)
strongTrend = adxVal >= adxThreshold
```
- **ADX > Threshold (Default: 20)** = Strong trend
- **DI+ > DI-** = Bullish momentum
- **DI- > DI+** = Bearish momentum
- **Why ADX?**
- Avoids trading in choppy markets (low ADX = weak trend)
- Confirms if Supertrend signals occur in a strong trend
---
### **C. MTF MA Filter (Higher Timeframe Trend Alignment)**
- **Moving Average Calculation:**
```pine
= getMA(maSource, maLength, maType, maTF)
```
- **MA Type:** SMA, EMA, WMA, or DEMA
- **Timeframe:** Any (1m, 5m, 1H, 4H, D, W, M)
- **Trend Direction:**
- **Buy Signal:** MA must be **rising**
- **Sell Signal:** MA must be **falling**
- **Why MTF MA?**
- Aligns trades with the **higher timeframe trend**
- Reduces counter-trend entries
---
## **3. How to Use This Indicator**
### **A. Buy Conditions (All Must Be True)**
1. **Supertrend turns bullish** (price crosses above `up` line)
2. **ADX ≥ Threshold** (trend is strong)
3. **Higher timeframe MA is rising** (confirms bullish bias)
### **B. Sell Conditions (All Must Be True)**
1. **Supertrend turns bearish** (price crosses below `dn` line)
2. **ADX ≥ Threshold** (trend is strong)
3. **Higher timeframe MA is falling** (confirms bearish bias)
### **C. Recommended Settings**
| Parameter | Recommended Value | Description |
|-----------|------------------|-------------|
| **ATR Period** | 14 | Sensitivity of Supertrend |
| **Multiplier** | 1.5-3.0 | Adjust for volatility |
| **ADX Threshold** | 20-25 | Higher = stricter trend filter |
| **MA Length** | 20-50 | Smoothness of trend filter |
| **MA Timeframe** | 1H/D | Align with trading style |
---
## **4. Trading Strategies**
### **A. Trend-Following Strategy**
- **Enter:** When all 3 conditions align (Supertrend + ADX + MA)
- **Exit:** When Supertrend flips or ADX drops below threshold
### **B. Pullback Strategy**
- **Wait for:**
- Supertrend in trend direction
- ADX remains strong
- MA still aligned
- **Enter:** On pullback to Supertrend line
### **C. Multi-Timeframe Confirmation**
- **Intraday traders:** Use 4H/D MA for trend bias
- **Swing traders:** Use D/W MA for trend bias
---
## **5. Advantages Over Standard Supertrend**
✔ **Fewer false signals** (ADX filters weak trends)
✔ **Higher timeframe alignment** (avoids trading against larger trends)
✔ **Customizable MA types** (SMA, EMA, WMA, DEMA)
✔ **Works on all markets** (stocks, forex, crypto)
---
### **Final Thoughts**
This indicator is designed for traders who want **high-confidence trend signals** by combining:
🔹 **Supertrend** (entry trigger)
🔹 **ADX** (trend strength filter)
🔹 **MTF MA** (higher timeframe trend alignment)
By requiring all three components to align, it significantly improves signal quality compared to standalone Supertrend systems.
**→ Best for:** Swing trading, trend-following, and avoiding choppy markets.
Markov Chain Trend ProbabilityA Markov Chain is a mathematical model that predicts future states based on the current state, assuming that the future depends only on the present (not the past). Originally developed by Russian mathematician Andrey Markov, this concept is widely used in:
Finance: Risk modeling, portfolio optimization, credit scoring, algorithmic trading
Weather Forecasting: Predicting sunny/rainy days, temperature patterns, storm tracking
Here's an example of a Markov chain: If the weather is sunny, the probability that will be sunny 30 min later is say 90%. However, if the state changes, i.e. it starts raining, how the probability that will be raining 30 min later is say 70% and only 30% sunny.
Similar concept can be applied to markets price action and trends.
Mathematical Foundation
The core principle follows the Markov Property: P(X_{t+1}|X_t, X_{t-1}, ..., X_0) = P(X_{t+1}|X_t)
Transition Matrix :
-------------Next State
Current----
--------P11 P12
-----P21 P22
Probability Calculations:
P(Up→Up) = Count(Up→Up) / Count(Up states)
P(Down→Down) = Count(Down→Down) / Count(Down states)
Steady-state probability: π = πP (where π is the stationary distribution)
State Definition:
State = UPTREND if (Price_t - Price_{t-n})/ATR > threshold
State = DOWNTREND if (Price_t - Price_{t-n})/ATR < -threshold
How It Works in Trading
This indicator applies Markov Chain theory to market trends by:
Defining States: Classifies market conditions as UPTREND or DOWNTREND based on price movement relative to ATR (Average True Range)
Learning Transitions: Analyzes historical data to calculate probabilities of moving from one state to another
Predicting Probabilities: Estimates the likelihood of future trend continuation or reversal
How to Use
Parameters:
Lookback Period: Number of bars to analyze for trend detection (default: 14)
ATR Threshold: Sensitivity multiplier for state changes (default: 0.5)
Historical Periods: Sample size for probability calculations (default: 33)
Trading Applications:
Trend confirmation for entry/exit decisions
Risk assessment through probability analysis
Market regime identification
Early warning system for potential trend reversals
The indicator works on any timeframe and asset class. Enjoy!
CRT Impulse Detector - Bull & BearHelps Identify Impulse Candles, only triggering those that break recent swings.