2-Sigma / 3-Sigma Volume Candle LevelsOn TradingView: Change 2m → 1m Turn Change Candle Colors off Turn on: 3σ Open/Close 3σ High/Low 2σ Open/Close 2σ High/LowChỉ báocủa Tradethechart16
Market Regime Engine [NQ Labs] WHAT THIS ANSWERS Almost every indicator tells you WHAT the market is doing. Very few tell you whether the current market has enough exploitable structure to be worth risking money on at all. The Market Regime Engine is built for that second question: should I be trading this right now, and if so, what style of approach do current conditions actually favour? It is not a signal generator. It produces no entries. It is a filter you run underneath whatever you already trade. WHY IT IS BUILT THIS WAY Two design decisions separate this from a conventional regime or trend filter. 1. EVERY AXIS IS PERCENTILE-RANKED AGAINST ITS OWN HISTORY. Most regime tools use fixed thresholds - an ADX of 25, an ATR multiplier of 3. Those numbers are calibrated to whatever the author tested on. They are the reason a tool behaves sensibly on one instrument and nonsensically on the next. Here, each axis is ranked against its own recent distribution on the current symbol and timeframe, so a 65th-percentile reading carries the same meaning on a crypto pair as it does on an FX major. Nothing needs retuning per market. 2. THE THREE AXES ARE ORTHOGONAL BY DESIGN. Many "confluence" tools stack three views of momentum and present the agreement as confirmation. Correlated inputs agreeing is not evidence. These three measure genuinely different properties: DIRECTIONAL EFFICIENCY - net distance travelled divided by the total path walked to get there. A value near 1 is a straight line. A value near 0 means price ended where it started after a great deal of work. This is the most direct available answer to "is there a trend here", and it is independent of direction. VOLATILITY STATE - ATR ranked against its own history. Not "is volatility high" in absolute terms, but "is volatility high for this instrument". RETURN PERSISTENCE - lag-1 autocorrelation of log returns. Positive means an up bar tends to be followed by an up bar, so momentum approaches have something to work with. Negative means the market reverts. Near zero means returns carry no usable memory. THE SCORING LOGIC The Tradeability Score (0-100) rests on one idea: Efficiency is the signal. Volatility is the cost of being wrong. Volatility only hurts you when there is no direction to exploit. So the noise penalty is the product of how little direction exists and how violent the market is. It approaches zero inside a strong trend no matter how wild conditions get - because volatility inside a trend is opportunity, not noise - and it peaks precisely where traders are most reliably ground down: low efficiency combined with high volatility. That specific combination is what the engine exists to flag. THE FIVE REGIMES TREND Efficiency high. Directional. Follow it. VOLATILE CHOP Efficiency low, volatility high. No direction, maximum cost of being wrong. The state that does the damage. COIL Efficiency low, volatility low. Compression. Wait. RANGE Efficiency low, volatility middling. Edges are tradeable. TRANSITION Efficiency mid-range. No clean read. Reduce size. A raw regime read must hold for a configurable number of consecutive bars before it is confirmed. Without that filter, readings that straddle a threshold flip back and forth for single bars. REGIME MATURITY - THE PART I HAVE NOT SEEN ELSEWHERE The engine records the length of every completed regime run on the current chart and reports the current run against that learned baseline, together with the sample size behind it. A trend at 0.3x its typical duration and a trend at 2.4x are not the same trade, even though every conventional indicator prints the identical reading for both. A compression that has lasted three times longer than compressions normally last on this instrument is a different proposition to one that started six bars ago. The sample size (n=) is shown deliberately. Below the configured threshold the cell dims, because a baseline built from two observations is not evidence and should not be dressed up as though it were. HOW TO USE IT The engine is a gate, not a trigger. The intended workflow: 1. Read the Verdict first. STAND DOWN means your edge, whatever it is, is probably not present. The most valuable output of this tool is the trades it talks you out of. 2. Read the Regime and Favoured Style. Trend-following systems belong in TREND. Mean-reversion belongs in RANGE, and only when Persistence confirms the market is actually reverting rather than merely quiet. COIL means the setup has not arrived yet. VOLATILE CHOP means nothing you own works here. 3. Read Persistence before choosing an approach. If it reads Random, the market has no memory to exploit in either direction, and both momentum and mean-reversion are coin flips. 4. Use vs Typical for position management, not entry. An extended regime is not a reversal signal. It is a reason to stop adding and to tighten what you already hold. 5. Let the ribbon and score do the work on the price chart. The dashboard can be forced onto the main pane so the engine occupies a pane without costing you chart real estate. SETTINGS THAT ACTUALLY MATTER RANKING LOOKBACK is the important one. It must span several complete regime cycles on your timeframe or every axis will rank near the middle and everything will read TRANSITION. 250 bars on a daily chart is roughly a year - a real baseline. 250 bars on a 5-minute chart is under a day, and is not. On intraday timeframes, raise it substantially. MINIMUM REGIME RUN trades responsiveness for stability. Higher values give a calmer read and a cleaner duration baseline at the cost of confirming changes later. Set it to 1 to see the unfiltered classification. CHOP PENALTY controls how hard low-efficiency volatility is punished. Set it to 0 and the score becomes pure efficiency rank. EFFICIENCY and VOLATILITY thresholds are percentiles, not raw values. They do not need adjusting per instrument. That is the point. LIMITATIONS - STATED PLAINLY - This is a lagging, descriptive tool. It classifies conditions that have already formed. It does not forecast, and it cannot tell you a regime is about to end. - Confirmation costs lag. A genuine regime change registers a few bars late by design. That is the price of not flickering. - The maturity baseline is learned from visible chart history and rebuilds whenever settings, symbol, or timeframe change. It is not persistent memory. Early in a chart, or for a rarely-occurring regime, the sample is thin. The n= value tells you when to discount it. - On intraday equity charts, overnight gaps inflate ATR and distort the persistence reading. Daily and above, or extended hours, handle this better. - Autocorrelation is a weak statistic on short samples. Persistence readings close to zero should be read as "no information", not as a subtle signal. - Efficiency is directionless. TREND tells you a trend exists, not which way it points. Pair it with something that reads direction. - No regime classification is correct at the moment it matters most, which is the turn. Nothing here changes that. This script is open-source. Read the code, disagree with it, improve it. This is an analytical tool for studying market conditions. It is not financial advice, and it does not generate trade recommendations. Trading involves risk of loss.Chỉ báocủa NQ_Labs5
Luxy UT God Mode - UT-Bot Forecast, Signals, Zones and RiskLuxy UT God Mode turns the classic UT Bot ATR trailing-stop into a complete, self-contained trading cockpit: momentum-adaptive buy/sell signals, a forward-looking Trend Duration Forecast, auto support/resistance zones, a 0-100 Confidence Score, a built-in multi-currency Risk Calculator, and automatic Stop Loss / Take Profit levels - all on one overlay, all non-repainting. Note: Every forecast, probability, and statistic in this tool is a calculation based on the chart's own historical behavior. They describe past patterns, not guaranteed future results. WHAT MAKES THIS DIFFERENT A normal UT Bot only tells you the trend flipped. Luxy UT God Mode answers the three questions a trader actually asks at the moment of a signal: 1. Should I trust this flip? - a Confidence Score (0-100) blends seven engines into one number. 2. How long might this trend run? - a Trend Duration Forecast projects the expected remaining life of the current trend, drawn as a fading strip with survival-probability milestones. 3. What do I risk and how big do I trade? - automatic Stop Loss, R-based Take Profits, and a position-size calculator in your own account currency. Everything is layered so you can run it bare-bones (just clean signals) or switch on the full "God Mode" stack. METHODOLOGY AND CREDITS This indicator implements proven concepts using entirely original code. - UT Bot ATR trailing logic - original concept by @QuantNomad . This implementation is a significant rework: it adds volume weighting, momentum-adaptive sensitivity, a composite multi-method stop loss, a full multi-filter confirmation stack, multi-timeframe confluence, and the statistical trend-duration engine described below. Important: this is an educational analysis tool. It does not guarantee any trading result. Always do your own analysis and manage risk. THE SEVEN ENGINES (and the Confidence Score that fuses them) Each bar, the script scores how well the current setup aligns and sums it into a single 0-100 Confidence Score with a visual progress bar: UT Bot direction - is price above/below the momentum-adaptive trailing stop SuperTrend - direction plus a distance-from-line strength bonus Market Structure - position inside the recent swing range and structure breaks ADX Regime - is the market trending (signals allowed) or choppy (blocked) Multi-Timeframe - does a higher timeframe agree with the signal direction Volume - is conviction backed by above-average volume RSI Divergence - is a recent divergence supporting or opposing the signal Read it at a glance: 80+ = strong, 60+ = good, 40+ = weak, under 40 = very weak. Hover the Confidence cell for the full per-engine breakdown. 1. TREND DURATION FORECAST - the headline feature When the trend flips, the script projects how many more bars the new trend may last, based on the chart's own past trends. How it works: Every completed trend's duration is recorded, kept separately for bullish and bearish trends. On each new flip the script estimates the expected duration using an exponentially-weighted average and standard deviation (recent trends weighted more heavily). The estimate is drawn as a fading gradient strip that projects forward from the flip, with a "Trend Analysis" label and survival-probability milestones at 25% / 50% / 75% / 90% / 100% of the projection. The percentages are empirical - they show the share of past same-direction trends on THIS chart that actually lasted at least that long. Not a fixed textbook curve. Three forecast modes: Simple - median duration only. Clean and fast. Standard - exponentially-weighted average plus spread (recommended default). Advanced - Standard plus five adaptive multipliers: Structure (proximity to S/R), Asset Type (volatility profile), Flip Strength (volume + filters passed), Error Learning (self-correction from its own past misses), and Regime (trending vs choppy). When history is thin, the forecast honestly falls back to a combined estimate and flags it, rather than showing false precision. 2. MOMENTUM-ADAPTIVE UT BOT CORE The trailing stop is not a fixed ATR multiple. The effective sensitivity adapts each bar to: Momentum - faster momentum widens the trail to stay in strong moves Relative volume - conviction adjusts the distance Asset type - auto-detected (crypto, forex, futures, index, fund, CFD, bond, stock) with a per-class multiplier, or set it manually Volatility mode - Fixed, Dynamic, or Aggressive auto-adjustment to the current volatility regime The result is a trailing engine that behaves differently on a calm blue-chip than on a volatile small-cap or crypto pair - without you re-tuning it. 3. ANTI-WHIPSAW AND SIGNAL FILTER STACK Signals only fire when they survive the filters you enable, so you control the trade-off between frequency and quality: ADX Regime - block signals in choppy, non-trending conditions Cooldown and Confirmation - minimum bars between signals and N-bar direction confirmation Swing - only trade aligned with recent swing structure Full Candle - require the whole candle beyond the trailing line (no straddles) Volume, RSI, Hull MA, SuperTrend - optional confirmation layers High-Volatility and % Change - only trade meaningful moves 2-Bar Confirm - extra confirmation for volatile markets Every active filter appears as a row in the table with a live pass/fail state, so you always know why a flip did or did not become a signal. 4. SUPPORT / RESISTANCE ZONES The script clusters significant swing pivots into persistent price zones and draws only the two that matter right now: the nearest resistance above price and the nearest support below price. Each zone shows its price and touch count (e.g. "S 4.19 (3x)" = a support tested three times). A level that price has broken through drops off automatically, and an optional Zone Filter can block buys into resistance and sells into support. Pivot strength is adjustable so you can show only major levels. 5. AUTOMATIC STOP LOSS, TAKE PROFIT AND RISK CALCULATOR On every signal the script draws a complete trade plan: Stop Loss - choose from seven methods: ATR, % based, tick based, swing, scaled ATR, Smart Adaptive (auto-scales to volatility), or Safer (widest of several). Take Profit - TP1 / TP1.5 / TP2 / TP3 as R multiples of the stop distance, with optional price and % labels, and a freeze-on-touch check mark for journaling. Entry line - marks the signal price; all lines can auto-limit to 10 bars for a clean chart. Risk Calculator - enter account size and risk (% or fixed amount) and it returns the position size in shares/contracts, in your own currency, with live FX conversion (USD, EUR, GBP, JPY, CAD, AUD, CHF) or a manual rate. 6. MULTI-TIMEFRAME CONFLUENCE AND RSI DIVERGENCE The table shows the trend of up to seven higher timeframes (5m, 15m, 30m, 1H, 4H, D, W) via an EMA 9/21 cross, so you can see whether the bigger picture agrees before you act. An optional MTF filter blocks counter-trend signals. Separately, RSI divergence (regular bullish and bearish) is detected, labeled on the chart, and fed into the Confidence Score. 7. LIVE STATUS TABLE A configurable dashboard (position and size adjustable) summarizes everything: asset type, Confidence Score, adaptive mode, current signal, win-rate / average-bars statistics, multi-timeframe row, divergence, forecast, position size, and one row per active filter - each with a detailed tooltip. HOW TO USE IT - QUICK START Step 1 - Add it and pick your sensitivity. Defaults suit intraday (5-15m). For scalping lower the Sensitivity/ATR; for swing raise them (see the Sensitivity tooltip for presets). Step 2 - Read a signal. A Buy (aqua, below bar) or Sell (orange, above bar) appears only after the bar closes and all enabled filters pass. Check the Confidence Score and the Multi-TF row for context. Step 3 - Use the trade plan. The Entry, Stop Loss and Take Profit lines draw automatically. Read the Position row for size. Use the Trend Duration Forecast strip as a realistic hold-time expectation - scale out near the median, reassess if price runs past the projection. Step 4 - Set alerts. Use "Any alert() function call" to receive BUY/SELL and trend-flip alerts on bar close, or pick the specific "Momentum Buy/Sell Signal" conditions. All alerts fire on confirmed bars only. TUNING FOR MORE OR FEWER SIGNALS Too few signals: turn off MTF, then Full Candle, then lower the ADX threshold or the Anti-Whipsaw filter. Too many / choppy: raise the ADX threshold, enable Volume and Full Candle, increase Cooldown, or add 2-Bar Confirm. Every filter is independent and shown live in the table. TECHNICAL NOTES Pine Script v6, overlay, max bars back 5000. No repaint: signals, lines, forecast and alerts are committed on bar close (barstate.isconfirmed); all higher-timeframe data uses lookahead_off. Works on stocks, crypto, forex, futures and indices, on any timeframe. Higher timeframes and longer history produce more reliable forecasts; a new symbol needs a number of completed trends before the duration model is meaningful. LIMITATIONS Trend-following by nature: signals arrive after a trend establishes, not at exact tops/bottoms. Best in trending conditions; use the ADX regime and filters to avoid chop. The duration forecast needs history to become meaningful and is a statistical estimate, never a guarantee. DISCLAIMER This script is an educational analysis tool, not financial advice. Trading stocks, crypto, forex and futures involves substantial risk of loss - you can lose all invested capital. Forecasts, probabilities and win-rate statistics are calculated from historical chart data and do not guarantee future performance. Test on paper first, and you are solely responsible for your own trading decisions. Feedback and suggestions are welcome in the comments. Happy trading. Chỉ báocủa orenluxyCập nhật 2929 1.8 K
Session Boxes-Mike_XAU A trading sessions indicator that shades the chart to show when the Tokyo, London, and New York sessions are open, so you can quickly see which session is active and spot overlaps (like London/NY, which usually brings the most volatility). Basic version just needs each session's open/close times, a colored box or vertical shading per session, and labels — nothing fancy, just a visual reference for when the big players are active.Chỉ báocủa mikesmith45526
IQE + Volume Bubbles Engine LiteIQE + Volume Bubbles Engine Lite Overview Recently I have just seen DeepCharts and BookMap and HeatMaps with Volume Bubbles. I trade XAUUSD and scalp that instrument and wanted this for TradingView. But realised the way TradingView implements Level 2 MBO data it would not be possible to implement the heatmaps and Volume Bubbles, but I cracked on regardless and created IQE. I was trying to identify Institutional Particpation . Then I came across Volume Bubbles (QuantAlgo) and how they implemented Volume Bubbles and thought I could implement that methodology, Then I put both indicators on the chart and thought how much richer the Indicators when merged together looked, giving increased insights into Volume. IQE + Volume Bubbles Engine Lite combines the Institutional Quality Engine (IQE) with an enhanced Volume Bubble Engine to identify high-quality institutional participation and volume events on a single chart. Rather than relying on volume alone, IQE analyses multiple aspects of market behaviour to classify the quality of each move before combining that information with significant Volume Bubble events. The result is a simple visual representation of potential institutional participation using three signal families: VI – Volume Bubble + IQE V – Volume Bubble Only I – IQE Only The Lite version is designed to provide a powerful institutional participation indicator while remaining easy to understand and configure. Institutional Quality Engine (IQE) IQE is an original multi-engine scoring model developed to evaluate the overall quality of market participation rather than relying on a single technical indicator. Every candle is analysed using five independent market components. Participation Engine Measures whether unusually large market participation is occurring by analysing: Relative volume Volume acceleration Volume persistence Candle expansion Overall participation quality This attempts to distinguish genuine participation from normal market activity. Efficiency Engine Evaluates how efficiently price moved during the candle. Factors include: Body size Wick size Close location ATR efficiency Directional close strength Strong institutional candles generally close efficiently with limited rejection. Structure Engine Evaluates market structure including: Break of previous highs/lows Breakout strength Range compression Close outside previous structure This helps identify meaningful structural moves rather than random price fluctuations. Trend Engine Analyses trend quality using: EMA trend direction Trend slope Higher highs Higher lows Lower highs Lower lows Trend continuation This helps distinguish trend participation from counter-trend movement. Liquidity Engine Evaluates potential liquidity behaviour including: Liquidity sweeps Rejection candles High-volume stalls Exhaustion characteristics The Lite version includes this internal liquidity assessment as part of the IQE score. IQE Classification Each candle is classified into one of three quality levels. PRO Professional participation. Represents above-average institutional quality and is often the earliest indication of meaningful activity. INST Institutional participation. Requires stronger agreement between the IQE engines and generally indicates higher confidence. EXCE Exceptional participation. Reserved for the strongest institutional-quality candles where multiple market conditions align. Volume Bubble Engine The Volume Bubble Engine identifies statistically significant volume clusters and classifies them into three levels. Small Medium Big Each cluster may be classified as: Buy Sell Mixed depending on the selected classification method. The Volume Bubble settings remain intentionally compatible with the original implementation. For a detailed explanation of the Volume Bubble detection methods, percentile settings, consensus modes and lower timeframe delta calculations, users are encouraged to refer to the original Volume Bubbles publication by QuantAlgo . Combined Signal Engine The Lite version introduces three independent signal families. VI Volume Bubble and IQE occur together. This represents the strongest confluence because both engines independently agree on institutional participation. V Volume Bubble only. Used when significant volume is detected without an accompanying IQE classification. I IQE only. Used when institutional-quality price behaviour is detected without a qualifying Volume Bubble. Consecutive Signal Confirmation One of the major additions in the Lite version is the ability to require multiple qualifying signals within a user-defined lookback period before a signal is displayed. This helps reduce isolated signals and instead highlights repeated institutional participation. Each signal family can be configured independently. VI Confirmation Require multiple VI signals within a configurable lookback window. Useful for confirming repeated institutional participation combined with elevated volume. V Confirmation Require multiple Volume Bubble signals. Useful for identifying persistent high-volume activity rather than isolated spikes. I Confirmation Require multiple IQE signals. Useful for confirming repeated institutional-quality behaviour even when volume remains below cluster thresholds. TDFI Trend Filter The Lite version includes an integrated TDFI v2 filter which can optionally suppress signals that occur against the prevailing trend. Two filtering modes are available. Threshold Hold Signals are permitted whenever TDFI remains inside its bullish or bearish threshold. This is the more responsive mode and generally produces more trading opportunities while still filtering obvious counter-trend signals. Momentum / Recovery Signals require both: TDFI to remain inside the bullish or bearish threshold Momentum to continue in the same direction (or remain pinned near an extreme) This is a stricter confirmation method designed for traders who prefer stronger trend continuation before allowing signals. Informative Alerts Dynamic alerts include: Signal family Buy or Sell direction IQE classification IQE score Volume Bubble level Volume ratio Delta information Signal occurrence count TDFI status Trend filter state Candle Colouring The indicator supports four colouring modes. Off IQE Only Volume Bubbles Only IQE + Volume Bubbles When both engines are enabled, Volume Bubble colours take priority while IQE colours remain visible on candles without an active Volume Bubble. Attribution This indicator combines original work with adapted open-source components. Original work nrendall Original developments include: Institutional Quality Engine (IQE) IQE scoring methodology Participation, Efficiency, Structure, Trend and Liquidity engines VI / V / I Combined Signal Engine Consecutive signal confirmation TDFI integration Dynamic alert system Candle colouring system Overall architecture and user interface Volume Bubble Engine This indicator includes an adapted implementation of the open-source Volume Bubbles indicator. Original author: QuantAlgo When using a laptop hovering over the Bubbles gives additional volume insights. This does work of a phone or tablet but does not work as well as when using a laptop TDFI Trend Filter This indicator includes an adapted implementation of TDFI v2. Original author: causecelebre The TDFI filter has been integrated into the IQE signal engine and extended with configurable filtering modes while respecting TradingView's House Rules for open-source scripts. Looking Ahead – IQE Professional IQE + Volume Bubbles Engine Lite is the community edition of the IQE platform. The upcoming IQE Professional will introduce a completely new proprietary architecture, including: Institutional Absorption Engine - Completed EMA Squeeze / Market State filter showing Squeeze and Ranging Markets - Completed Participation Persistence Engine Advanced Liquidity Analysis Institutional Confidence Scoring Multi-engine confirmation Advanced dashboards Premium alerts Iceberg Identification Multi-timeframe participation analysis Accumulation and distribution regimes Institutional continuation and reversal models Liquidity sweep sequences Reload and estimated iceberg behaviour Cross-engine confluence scoring Configurable trade-rating framework Session and regime analytics Research/export tools These may have to be split into two different indicators as the Pro is already 3000+ lines and creeping towards the max of PineScript. Additional institutional market analytics The long-term goal is the IQE Institutional Suite, bringing together original institutional participation and market-structure analysis into a unified professional trading platform.Chỉ báocủa nrendall23
NQ/ES Morning Dashboard v1.4Dashboard to help identify possible NQ manipulation candles from 9:30 am to 11:30 am EST (New York open plus 2 hours). Updated Overnight high and Low display and updated display of metrics shown on price axis (removed a few).Chỉ báocủa clfancher3
QUANT $brainwash yourself till u rich - go make art, go make bank, go fullfilled some prophecies. different order of human experience Chỉ báocủa aurasaintt33159
Institutional Flow MatrixInstitutional Flow Matrix is an open-source market-analysis framework designed to organize trend direction, confirmed market structure, institutional price zones, momentum, and location within a dealing range into one readable chart. The purpose of this indicator is not to predict every price movement or generate constant entries. It is designed to answer a more practical sequence of questions: 1. What is the current directional bias? 2. Is market structure supporting that direction? 3. Is price trading from a meaningful location? 4. Has price returned to an active institutional zone? 5. Is momentum aligned with the proposed setup? The script combines these questions into a structured workflow while keeping the default chart intentionally clean. WHY THIS INDICATOR WAS BUILT Many market-structure indicators display every swing, imbalance, liquidity level, zone, and signal at the same time. While that information can be useful for detailed analysis, it can also make the chart difficult to interpret during live trading. Institutional Flow Matrix was built around a visual hierarchy: * Directional bias is the primary layer. * Active Order Blocks are the principal reaction zones. * Momentum is a confirmation layer. * Premium and Discount provide market location. * Fair Value Gaps, liquidity pools, sweeps, and higher-timeframe levels are optional study tools. The default Balanced preset focuses on the information most relevant to a directional pullback setup. Minimal mode removes most supporting visuals for live execution. Full mode reveals the additional market-structure tools for deeper analysis. WHAT MAKES THE IMPLEMENTATION DIFFERENT The individual concepts used by this script, including pivots, moving averages, ATR trend filters, Order Blocks, Fair Value Gaps, and Premium/Discount ranges, are established forms of technical analysis. The original contribution of Institutional Flow Matrix is how those components are synchronized and managed as one decision framework. Key design elements include: * Confirmed structure events rather than unconfirmed swing guesses. * A persistent directional state requiring agreement between structure, EMA alignment, and an ATR-based trend filter. * Order Block freshness validation before a zone is accepted. * Separate visual duration and analytical lifetime controls for zones. * Automatic mitigation and expiration of old zones. * Limited drawing-object counts to prevent long-term chart clutter. * A weighted confluence model centered on trend, structure, zone interaction, market location, and momentum. * Three visual presets that change the information hierarchy without changing the underlying calculations. * Confirmed-bar signals and event-based alerts. This is not intended to be a collection of unrelated indicators. Each module has a defined role in the same setup process. DIRECTIONAL BIAS The chart background represents the script's confirmed directional state. A bullish state requires agreement between: * Bullish market structure. * Fast EMA positioning above the slow EMA. * Bullish ATR trend conditions. A bearish state uses the opposite conditions. The background changes only after the required conditions are confirmed. A larger BUY or SELL label marks a confirmed change in this directional state. These shift labels are different from the smaller confluence signals. A shift label identifies a change in directional bias. A confluence signal requires additional location, zone, and momentum conditions. MARKET STRUCTURE Confirmed pivot highs and lows form the structure engine. The script tracks: * Higher Highs * Higher Lows * Lower Highs * Lower Lows * Breaks of Structure * Changes of Character A bullish break occurs when a confirmed bar closes above the latest unbroken confirmed swing high. A bearish break occurs when a confirmed bar closes below the latest unbroken confirmed swing low. Swing labels are retrospective by design. A pivot can only be confirmed after the selected number of right-side bars has closed. Once confirmed, its label is placed on the candle where the swing originally occurred. The label was not known on that earlier candle. ORDER BLOCKS Order Blocks are the primary reaction zones in the indicator. After a confirmed structure break or qualifying displacement event, the script searches backward for an opposing candle. A candidate candle can be filtered by: * Candle range relative to ATR. * Body size as a percentage of candle range. * Optional volume expansion. * Wick-based or body-based zone construction. Before accepting the candidate, the script checks whether price has already invalidated it. This prevents many stale zones from being created after the fact. Active Order Blocks can be invalidated by either: * A close beyond the opposite edge. * A wick beyond the opposite edge. The selected mitigation method is used consistently during both zone creation and live zone management. Order Blocks have separate controls for visual extension and analytical age. This allows users to control how long a box remains visible independently from how long it remains eligible for signal calculations. PREMIUM, DISCOUNT, AND EQUILIBRIUM The script creates a rolling dealing range from the highest high and lowest low over the selected lookback. The range is divided into: * Premium: the upper portion of the range. * Discount: the lower portion of the range. * Equilibrium: the 50% midpoint. Premium and Discount do not generate trades by themselves. They provide location. In general: * Bullish setups receive stronger contextual support in Discount. * Bearish setups receive stronger contextual support in Premium. * Equilibrium represents the midpoint of the current rolling range. Because the range is rolling, its boundaries can change when a new lookback high or low is formed. MOMENTUM RIBBON The momentum module uses three exponential moving averages and an ATR-normalized difference between the fast and slow averages. Bullish momentum requires: * Fast EMA above the slow EMA. * Positive normalized momentum. * Momentum above its signal average. Bearish momentum uses the opposite conditions. Diamond markers identify confirmed momentum crossings. The ribbon is intended as confirmation rather than a standalone entry system. CONFLUENCE SIGNALS The script calculates a 0-100 Confluence Score from five conditions: * Directional bias: 25 points. * Market structure: 15 points. * Momentum alignment: 15 points. * Active Order Block interaction: 25 points. * Premium or Discount location: 20 points. The score measures condition alignment. It is not a probability, win rate, accuracy estimate, or forecast of future performance. By default, BUY and SELL signals require: * Confirmed directional bias. * Matching confirmed structure. * Interaction with an active Order Block. * Correct Premium or Discount location. * Matching momentum. * Minimum Confluence Score. * Completion of the selected signal cooldown. Signals are displayed only when the complete condition changes from false to true. This prevents repeated labels while the same setup remains active. OPTIONAL ADVANCED MODULES Full mode provides additional analytical tools: * Fair Value Gaps with ATR size filtering. * Equal-high and equal-low liquidity pools. * Confirmed liquidity sweeps. * BOS and CHoCH labels. * HH, HL, LH, and LL labels. * Previous day, week, and month highs and lows. * Optional momentum candle coloring. These features are disabled or hidden from the default Balanced view to preserve readability. VISUAL PRESETS Minimal: Designed for traders who want the least chart interference. It suppresses the background, ribbon, Premium/Discount display, trailing line, dashboard, and advanced structure annotations. Balanced: The default view. It emphasizes directional background, active Order Blocks, Premium/Discount context, momentum ribbon, diamonds, signals, and the dashboard. Full: Designed for detailed study. It adds structure labels, BOS/CHoCH events, Fair Value Gaps, liquidity tools, higher-timeframe levels, and optional candle coloring. FOR NEWER TRADERS A simple workflow is: 1. Start with the Balanced preset. 2. Use the background to identify the current directional bias. 3. Wait for price to return to an Order Block matching that bias. 4. Check whether price is in Discount for a bullish setup or Premium for a bearish setup. 5. Confirm that the momentum ribbon agrees. 6. Treat the signal as a point for further analysis, not an automatic order. The equilibrium line can be used as a reference for the midpoint of the current dealing range. It is not automatically an entry or exit instruction. FOR ADVANCED TRADERS Experienced users can customize: * Pivot confirmation sensitivity. * ATR and EMA trend parameters. * Wick-based versus body-based Order Blocks. * Displacement-created zones. * Candle body, range, and volume filters. * Close-based versus wick-based mitigation. * Zone visual duration and analytical age. * Premium and Discount percentages. * Fair Value Gap size. * Liquidity sensitivity. * Momentum lengths. * Individual signal requirements. * Minimum confluence threshold. * Signal cooldown. * Higher-timeframe reference levels. Advanced users can also disable individual hard requirements and use the Confluence Score as a more flexible filtering system. ALERTS Alert conditions are included for: * Break of Structure. * Change of Character. * New Order Block. * BUY signal. * SELL signal. * Bias-aligned Order Block entry. * Trend and momentum confluence. * Liquidity sweep. Alerts should be created using Once Per Bar Close when confirmed signals are required. NON-REPAINTING AND TIMING Structure breaks, directional shifts, zone creation, zone mitigation, momentum events, and confluence signals are evaluated on confirmed bars. Pivot-based swing labels require future bars to confirm that a swing occurred. After confirmation, the label is displayed on the original pivot candle. This is delayed confirmation with retrospective placement, not advance knowledge of the swing. Previous-period levels use completed higher-timeframe data. LIMITATIONS * This indicator does not predict future prices. * It does not calculate position size, stop loss, or account risk. * It is not a complete automated trading system. * Signals can fail during volatile, illiquid, or range-bound conditions. * Rolling Premium, Discount, and equilibrium levels can move when the lookback range changes. * Confirmed pivots introduce an intentional delay. * Order Block definitions vary among trading methodologies; this script uses the documented candle-search and filtering rules described above. * Volume behavior differs across asset classes and data providers. * Parameter settings that work on one symbol or timeframe may not be appropriate for another. Suggested starting points are the 15-minute and 1-hour charts for intraday analysis and the 4-hour chart for broader swing structure. Users should test settings on their own symbols and trading sessions. OPEN-SOURCE PURPOSE The script is published open-source so traders can inspect the calculations, understand why signals occur, verify the confirmed-bar methodology, and adapt the framework for their own research. The goal is to provide a readable and transparent market-structure workflow rather than a black-box prediction tool. DISCLAIMER This indicator is provided for educational and analytical purposes only. It is not financial advice and does not guarantee profitable results. Historical chart behavior does not ensure future performance. Users are responsible for their own analysis, testing, risk management, and trading decisions. Chỉ báocủa Finntech13347
Price Action Concepts [b1k]Price Action Concepts everything i actually watch on an intraday chart, in one indicator. built off my Essential Time Ranges and folded in the tools i kept loading separately. what's inside: Time ranges — hourly high/low + midpoint, opening range (30s up to 30m, pulled from lower-timeframe data so it's accurate on any chart and extends across RTH), initial balance (9:30-10:30), and the RTH box. Range metrics — ADR(10), AWR(8), today's day range and this week's range, plus % of each used so you know how much is left in the tank. ADR/AWR projected off the open (open +/- range/2), same read as Quant Matrix. Value areas — VAH / VAL / POC for the session you choose (RTH or ETH), both TPO and volume profile, plus the last 3 sessions. volume draws as a zone, TPO as lines. also marks TPO single prints and volume imbalances (low-volume nodes) for the fast-move levels. 1kpier levels — overnight high/low, previous day and week high/low, wickless 15m candles, and a reference grid. HoD/LoD timing — where the high and low of the range printed and how long it took to get there. Session distributions — the Quant Matrix boxes (each session sized to its own average range, centered on the open) and the distribution table, total or by day of week, points or percent. built around ES/NQ but the ratios carry across instruments. every element has its own color, line type and width, so you can set it up to read the way you want and turn off what you don't use. - b1kPier Chỉ báocủa b1kPierCập nhật 45
Dynamic Buying and Selling Power (ADTM) 什么是 ADTM? ADTM(Dynamic Buying and Selling Power Indicator,动态买卖气指标)是一种经典的动量与反转量化指标。它通过对比开盘价的跃升与下挫,精确量化开盘后多空双方的推进力度(即爆发力),并将这种力量对比归一化在 的固定区间内。 与传统单纯依赖收盘价(Close)的振荡指标不同,ADTM 更加关注 开盘价(Open)相对于前一交易日的位置以及当日极值(High/Low)的延伸空间 ,从而能够更敏锐地捕捉到市场资金的日内异动。 --- 为什么使用它? 在波诡云谲的市场中,单纯的均线或 lagging 指标容易产生钝化。ADTM 的优势在于: 无量纲化区间:其输出被严格限制在 之间,避免了绝对数值对趋势研判的干扰。 日内真实动能:通过计算买方动态能量(DTM)和卖方动态能量(DBM),能够更早地在左侧识别出多空力量的衰竭点。 极佳的反转提示:特别适合配合超买超卖边界进行逆势(反转)波段的卡点操作。 --- 怎么用? 本指标的使用逻辑非常直观,默认参数为经典配置: N = 23(求和周期),M = 8(信号均线周期)。 左侧买点(超卖区): 当蓝色 ADTM 曲线跌破 -0.5 时,意味着市场短期内空头宣泄极快,进入超卖状态。这通常是极佳的左侧分批布局或观察止跌反转的买点。 左侧风险(超买区): 当蓝色 ADTM 曲线突破 +0.5 时,意味着多头短期冲锋过急,进入超买状态。此时应防范多头力竭回撤,注意锁定利润或降低仓位。 中轴信号: 0轴为多空分界线。当 ADTM 在 0 轴上方运行时,多头占优;反之,空头占优。 均线交叉: 蓝色主线(ADTM)与橙色信号线(MA_ADTM)的黄金交叉与死亡交叉,可作为右侧动能确认的辅助信号。 --- 在哪里用? 本指标采用纯粹的价格几何结构算法,具有极强的普适性: 适用市场:广泛适用于 A 股、美股、加密货币、商品期货以及外汇等主流交易市场。 适用周期:在日线(Daily)及以上大周期中表现尤为稳定,能够有效过滤盘整期的日内噪音;在小周期(如 1H/4H)中,配合趋势背景亦可用于日内波段捕捉。 --- 原创与致谢声明 指标原创作者: 本指标的核心算法源自经典量化分析领域的经典设计。 脚本重构与发布: 由本人进行 Pine Script v6 的标准化重构、算法优化与开源发布。 风险提示: 任何技术指标都无法百分之百预测市场。建议将 ADTM 融入自身的交易系统中,结合量价结构、关键支撑阻力位以及严谨的资金管理共同使用。 --- What is ADTM? ADTM (Dynamic Buying and Selling Power Indicator) is a classic momentum and reversal quantification tool. It precisely quantifies the offensive strength (i.e., explosive power) of both bulls and bears after the market opens by comparing the upward jumps and downward drops of the opening price, and normalizes this power comparison within a fixed range of . Unlike traditional oscillators that rely solely on the closing price (Close), ADTM places greater emphasis on the opening price (Open) relative to the previous trading day's position, as well as the extension space of the day's extremes (High/Low) , enabling it to more keenly capture intraday anomalies in market capital flow. --- Why Use It? In volatile and unpredictable markets, simple moving averages or lagging indicators are prone to desensitization (flattening). The advantages of ADTM are: Dimensionless interval: Its output is strictly confined within , eliminating the interference of absolute price levels on trend assessment. Intraday true momentum: By calculating Dynamic Buying Momentum (DTM) and Dynamic Selling Momentum (DBM), it can identify exhaustion points of bullish/bearish power earlier on the left side. Excellent reversal signals: Particularly well-suited for contrarian (reversal) swing trading by utilizing overbought/oversold boundaries. --- How to Use It? The usage logic of this indicator is highly intuitive, with default parameters set to the classic configuration: N = 23 (Summation Period), M = 8 (Signal MA Period). Left-side Buy Signal (Oversold Zone): When the blue ADTM line drops below -0.5, it indicates that bearish forces have been excessively unleashed in the short term, entering an oversold state. This is typically an excellent opportunity for left-side accumulation or observing for a bullish reversal. Left-side Risk Signal (Overbought Zone): When the blue ADTM line rises above +0.5, it indicates that bullish forces have pushed too aggressively in the short term, entering an overbought state. At this point, one should be cautious of bullish exhaustion and pullbacks, and consider locking in profits or reducing positions. Zero-Line Signal: The 0.0 axis serves as the bull-bear dividing line. When ADTM is above 0, bulls are in control; when below 0, bears are in control. Moving Average Crossover: The golden cross and death cross between the blue main line (ADTM) and the orange signal line (MA_ADTM) can serve as auxiliary signals for right-side momentum confirmation. --- Where to Use It? This indicator employs a pure geometric price-structure algorithm, offering strong universality: Applicable Markets: Widely applicable to A-shares, U.S. stocks, cryptocurrencies, commodity futures, forex, and other major trading markets. Applicable Timeframes: Performs particularly well on Daily and higher timeframes, effectively filtering out intraday noise during consolidation periods. On lower timeframes (e.g., 1H/4H), it can also be used for intraday swing trading when combined with the broader trend context. --- Acknowledgments & Originality Statement Original Author: The core algorithm of this indicator originates from classic designs in the field of quantitative analysis. Script Re-engineering & Release: This script has been fully refactored, optimized, and released as open-source by myself. Risk Disclaimer: No technical indicator can predict the market with 100% accuracy. It is strongly recommended to integrate ADTM into your own trading system, combining it with volume-price structure, key support/resistance levels, and strict risk management practices.Chỉ báocủa william_wq7
R SNIPERinput.int(14, 'ATR Length', group = grp3) tp_mult = input.float(2.0, 'TP Multiplier', group = grp3) sl_mult = input.float(1.0, 'SL Multiplier', group = grp3)Chỉ báocủa rhyme173
Alpha Forge Core v6.4.15Alpha Forge Core v6.4.15 Advanced trend, momentum, structure, trade-management, and webhook automation indicator. This multi-layer decision-support tool is designed to help traders evaluate trend direction, momentum, market regime, price structure, entry conditions, and active trade management from one chart. Rather than relying on a single crossover or isolated signal, the system combines several confirmation layers to assess whether conditions support a potential long or short setup. It is intended for discretionary chart analysis, TradingView alerts, and compatible webhook-based automation. What the indicator analyzes The script evaluates: Trend direction Moving-average alignment Momentum strength Adaptive market regime Higher-timeframe confirmation Price structure Breakout conditions Pullback and reclaim behavior Entry distance and price extension Volatility Signal quality Active trade state Protective stop placement Profit-target progression Breakeven protection Trailing-stop protection These components are combined into a single decision process rather than displayed as unrelated signals. Automatic market detection The system can detect the general symbol type using TradingView market information. Supported categories include: Stocks ETFs Crypto Forex Futures Other supported symbols When automatic behavior is enabled, the detected market can influence the effective operating configuration. Crypto scalping behavior When a crypto symbol is detected, the script can automatically apply its faster Crypto Scalping configuration. This mode is designed for shorter-term crypto charts and removes higher-timeframe influence from the effective scoring process. Recommended crypto timeframe: 5 minutes Pine Script cannot automatically change the chart timeframe. When the current chart does not match the recommended timeframe, the Guide may display a reminder. Operating presets Scalping Designed for shorter timeframes and faster-moving setups. This preset uses more responsive conditions and shorter trade-development windows. Day Designed for intraday trading with a balance between responsiveness and confirmation. This is the recommended starting point for many stock and ETF charts. Swing Designed for higher timeframes and slower-developing setups. This preset applies more selective confirmation and allows additional time for trades to develop. Custom Allows the available settings to be controlled manually. Suggested starting points: Stocks and ETFs: 15-minute chart with Day mode Crypto: 5-minute chart with automatic Crypto Scalping Short-term scalping: 3-minute to 5-minute charts Swing trading: 30-minute to 4-hour charts These are general starting points only. Settings should be evaluated on the intended symbol and timeframe. Signal grades Potential entries can be filtered by grade. Available options include: A Only B Only A and B All Grades A-grade setups represent stronger internal alignment. B-grade setups may appear earlier or with fewer confirmation layers while still meeting the selected eligibility rules. C-grade setups represent lower-confirmation conditions and are available when All Grades is selected. Grades describe the amount of confirmation present at the time of the setup. They do not guarantee a particular outcome. Entry behavior The engine can identify several types of setup behavior. Breakout entries These occur when price moves through an important structure level with sufficient directional confirmation. Impulse entries These identify stronger directional expansion when momentum and price accelerate together. Early reclaim entries These occur when price briefly loses a key level and then reclaims it with confirmation. Continuation entries These identify opportunities within an established trend after a valid pullback or consolidation. B-grade re-entry When enabled, the system can permit a controlled re-entry after a valid pullback instead of repeatedly triggering during the same move. Range and extension protection The script includes filters intended to reduce weaker entries during unsuitable conditions. These can include: Blocking continuation setups in range conditions Requiring trend-regime eligibility Limiting entries when price is too far from its reference level Avoiding repeated entries during an active trade Waiting for candle-close confirmation Requiring directional confirmation These filters are designed to improve consistency, but they may also reduce signal frequency. Higher-timeframe confirmation Higher-timeframe alignment can be used as an additional confirmation layer. The script supports both responsive and confirmed higher-timeframe behavior. When higher-timeframe influence is disabled, scoring is normalized so that the missing HTF component does not unfairly reduce setup quality. Trade lifecycle The indicator tracks a complete trade state from entry through exit. The lifecycle can include: Entry confirmation Protective stop placement TP1 TP2 TP3 Breakeven activation Trailing-stop activation Stop-loss exit Breakeven exit Trailing-stop exit Final target exit Only one active position is tracked at a time. New entries are blocked until the current position is closed. Protective stops Stops can use a combination of structure and ATR-based distance. Available controls may include: ATR stop multiplier Structure buffer Maximum stop distance Same-bar target and stop priority Breakeven activation Trailing-stop source Trailing-stop distance These settings should be matched to the symbol’s volatility and the trader’s risk plan. Profit targets The system supports three target levels: TP1 TP2 TP3 Target progress is shown on the chart and in the dashboard. Breakeven and trailing protection can be activated after a selected target is reached. Forge Guide The Guide has been rebuilt as a forward-looking coaching panel. Instead of repeating dashboard information, it focuses on what matters next. It can display: What the system is waiting for What to watch next Whether a setup is armed Trigger conditions Invalidation conditions Remaining setup window Whether price is too extended Current trade objective Active protection Target progression Trailing-stop status Typical Guide states include: WAIT WATCH LONG WATCH SHORT LONG NEAR READY SHORT NEAR READY STAND ASIDE DO NOT CHASE MANAGE LONG MANAGE SHORT PROTECT PROFIT The Guide is intended to explain the current condition in plain language without replacing personal judgment. Dashboard The compact dashboard focuses on live decision information. It may display: Effective preset Detected market Trend Adaptive regime B eligibility Momentum Higher-timeframe state Structure Current decision Active trade Protection Last exit TP1, TP2, and TP3 status Historical testing statistics and diagnostic counters are not shown in the public dashboard so the chart remains clean and easy to read. Alerts and webhook automation The script supports TradingView alerts and JSON webhook messages. For long-only automation: buy opens a long position sell closes the long position A sell action may be generated when the active long closes through: TP3 Stop loss Breakeven Trailing stop Another enabled long-exit condition The JSON format includes fields for: Secret token Ticker Asset type Action Price Strategy Timeframe Order type Stop loss Take-profit levels For webhook use: Enter the secret token in the alert settings. Enable bot JSON alerts. Create one TradingView alert using Any alert() function call. Enter the webhook URL supplied by the connected execution service. Recreate alerts whenever the script or alert configuration is changed. Existing alerts continue running the older saved script snapshot until they are recreated. Important notes This indicator is a chart-reading and decision-support tool. It does not predict future price movement and does not guarantee profitable outcomes. Historical chart behavior may differ from live execution because of: Spread Slippage Liquidity Latency Broker rules Order handling Market gaps Partial fills Signals should be evaluated alongside personal risk management, position sizing, market conditions, and independent analysis.Chỉ báocủa Alpha_ForgeCập nhật 55217
Reversal Confluence Sniper [JOAT]Reversal Confluence Sniper Hunts exhaustion reversals by requiring several independent exhaustion signals to appear together, so it fades stretched moves with confirmation rather than hope. What it is Fading a trend is dangerous when done on a single cue. This indicator only flags a potential reversal when multiple, independent signs of exhaustion coincide at the same moment — turning a risky counter-trend guess into a confluence-gated setup. It is an original reversal engine, not a lone oscillator flip. How it works The engine looks for several exhaustion conditions and requires enough of them to align: • Momentum extreme — an oscillator reaching and rolling over from an overextended level, showing the push is losing force. • Volatility stretch — price extended a statistically large distance from a mean or band, marking an unsustainable move. • Rejection candle — a wick or close that rejects the extreme, showing the aggressive side failed to hold new ground. • Participation — a volume or effort read that flags climax or fade behaviour rather than steady continuation. A Buy (bullish reversal) prints when enough downside-exhaustion factors align; a Sell when enough upside-exhaustion factors align. A minimum-gap control prevents repeated prints while a market chops around an extreme. Trade levels Each signal draws a red risk box to a stop placed beyond the exhaustion extreme and a green reward box to the third target, with inner dividers and right-edge labels for entry, stop and each take-profit at your R multiples. Placing the stop beyond the extreme respects the idea that if price makes a new extreme, the reversal thesis is wrong. The dashboard An adjustable sniper-scope panel shows which exhaustion factors are currently active, a combined conviction reading, the active signal, and a live first-target-before-stop tally from closed bars only, so you can see how much confluence backs each setup. How to use it • Works on any asset and timeframe. • Most effective for timing entries at the end of a stretched move, ideally into a higher-timeframe level or zone. • Because it fades momentum, pair it with structure or a level tool and keep stops disciplined — reversals that do not confirm should be cut quickly. Settings The exhaustion factor lengths and thresholds, the number of factors required to trigger, risk multiple and target R multiples, plus visual and dashboard controls. Originality and usefulness The contribution is the confluence gate itself: several independent exhaustion measures that must agree before a counter-trend signal is allowed, with a transparent readout of which factors fired and integrated, non-repainting trade framing. It is designed to make fading safer by demanding evidence, not to promise reversals. Notes and limitations • Counter-trend trading is inherently higher risk; strong trends can stay stretched far longer than expected and overrun any reversal signal. • Requiring more factors reduces false signals but also reduces frequency — this trade-off is yours to set. • The tally reflects only past bars on the current chart and is not a forecast. • Educational and analytical tool, not financial advice. — made with passion by officialjackofalltrades Chỉ báocủa officialjackofalltrades268
BBI Dynamic Deviation Bands [William_wq] 这是一个什么样的指标? 简单来说,这是一个 “自带安全边界的趋势导航仪” 。 它把交易者最常用的四条不同周期的均线(超短期、短期、中期、长期)融合在一起,提炼出一条最敏锐的 多空分水岭(BBI主线) 。 为了防止大家在交易中“追高被套”或“抄底抄在半山腰”,我在这条主线的上下两侧,加上了 两层会动态变宽变窄的“安全气道”(波动通道) 。这就像是给价格装上了防撞护栏,一眼就能看出价格是处于“正常散步状态”还是“跑得太快快要累死了”。 --- 这个指标怎么用? 使用这个指标非常简单,只需要看懂 颜色和位置 : 1. 看颜色认方向(顺势而为) 绿色通道:代表目前是安全的多头(上涨)趋势。 红色通道:代表目前是危险的空头(下跌)趋势。 顺势原则:绿色只买不卖,红色只卖不买。 2. 看位置找机会(买卖点定位) 回调买入点(顺势上车): 当大趋势 是绿色 时,价格每次跌回中间的“BBI主线”或者“1.0倍下轨”附近,只要跌不下去,就是极佳的“顺势买入”机会。 极端预警点(落袋为安/反转提防): 价格是有弹性的,不可能一直涨。当价格猛烈冲出最外层的 “2.0倍外轨”时,说明多头跑得太累了,这时候 千万不要去追高 ,反而应该考虑分批止盈,或者等待行情反转。 --- 这个指标适合在哪里用? 适用的市场: 不管是 数字货币(BTC/ETH)、外汇黄金、还是美股/A股 ,只要有波动、有趋势的市场,它都能提供非常清晰的参考。 适用的时间周期: 日线 / 4小时线(中长线):适合上班族,用来过滤市场噪音,稳稳地抓住一波主升浪。 5分钟 / 5分钟(超短线/日内):适合职业交易员,用来捕捉当天价格波动的极端高低点,进行快速的高抛低吸。 --- 交易员寄语 “交易不仅要看清方向,更要看清价格所处的位置。” 希望这个工具能成为您交易系统里的得力助手。指标虽好,但也请配合好您的资金管理和止损纪律,祝大家交易顺利! --- What kind of indicator is this? Simply put, this is a "trend navigator with its own safety margins" . It merges four moving averages of different periods most commonly used by traders (ultra-short, short, medium, and long-term) into one, extracting the most sensitive bull/bear dividing line (the BBI main line) . To prevent everyone from "getting trapped by chasing highs" or "buying the bottom halfway down the hill," I have added two layers of "safety air cushions" (volatility channels) that dynamically widen and narrow on both sides of this main line. This is like installing crash barriers for the price, making it easy to see at a glance whether the price is "walking normally" or "running too fast and about to exhaust itself." --- How to use this indicator? Using this indicator is very simple—you only need to understand the colors and positions : 1. Look at the color to identify the direction (Go with the trend) Green channel: Represents a safe bullish (upward) trend. Red channel: Represents a dangerous bearish (downward) trend. Trend principle: Only buy and do not sell in green; only sell and do not buy in red. 2. Look at the position to find opportunities (Pinpointing entry and exit points) Pullback buying point (Hop on the trend): When the major trend is green , every time the price drops back near the middle "BBI main line" or the "1.0x lower band," as long as it holds, it is an excellent opportunity for a "trend-following purchase." Extreme warning point (Take profit / Beware of reversal): Price is elastic and cannot rise forever. When the price violently breaks out of the outermost "2.0x outer band," it means the bulls are running too tired. At this time, do not chase the high under any circumstances ; instead, you should consider taking profits in batches or waiting for a trend reversal. --- Where is this indicator suitable for use? Applicable markets: Whether it is cryptocurrencies (BTC/ETH), forex and gold, or US stocks / A-shares , as long as it is a market with volatility and trends, it can provide very clear references. Applicable timeframes: Daily / 4-hour chart (medium to long-term): Suitable for office workers to filter out market noise and steadily catch a major rising wave. 15-minute / 5-minute chart (scalping / intraday): Suitable for professional traders to capture the extreme highs and lows of the day's price fluctuations for quick buying low and selling high. --- Trader's Message "Trading is not just about seeing the direction clearly, but more importantly, seeing the position where the price is located." I hope this tool can become a powerful assistant in your trading system. Although the indicator is great, please also coordinate it with your capital management and stop-loss discipline. Wish everyone successful trading!Chỉ báocủa william_wq7
Swing Reversion Zones Swing Reversion Zones is an adaptive mean-reversion channel built around a smoothed price trajectory. It highlights the first moments when price reaches the upper or lower boundary of the channel. The indicator is designed to help traders evaluate how far price has moved away from its local smoothed structure and identify areas where a return toward the central trajectory may become possible. Boundary touches are displayed as semi-transparent bubbles: 🔴 Red bubble — touch of the upper boundary 🟢 Green bubble — touch of the lower boundary The bubbles show that price has reached a user-defined deviation zone. They are not automatic buy or sell commands. ━━━━━━━━━━━━━━━━━━ 🧭 Core Concept The indicator is based on the concept that price may revert toward a smoothed central trajectory after reaching a sufficiently large deviation from it. The central line is not calculated as a conventional moving average. Instead, the script uses Gaussian weighting. Bars located closer to the calculated point receive greater weight, while the influence of more distant observations gradually decreases. This approach is designed to: • reduce the influence of short-term market noise • preserve the natural shape of price movement • create a smooth central trajectory • measure deviations relative to local market structure rather than a conventional fixed moving average ━━━━━━━━━━━━━━━━━━ ⚙️ How the Channel Is Calculated The calculation consists of several connected stages. 1. Central Trajectory For each historical bar, the script calculates a smoothed value of the selected price source. The weight of each observation is determined by a Gaussian function. The closer an observation is to the point being calculated, the more influence it has on the resulting value. The Smoothing Length parameter controls the degree of smoothing: • lower values make the central line more responsive to local price movements • higher values create a smoother trajectory that reflects broader market structure 2. Base Deviation After calculating the central trajectory, the script measures the absolute distance between the selected price source and the smoothed line across the processed data. These distances are averaged to produce the base deviation value. Unlike channels based on ATR or standard deviation, Swing Reversion Zones uses the mean absolute error between price and the Gaussian-smoothed trajectory. 3. Upper and Lower Boundaries The distance from the central trajectory to each boundary is calculated as: Mean Absolute Deviation × Channel Width The resulting value is: • added to the central trajectory to create the upper boundary • subtracted from the central trajectory to create the lower boundary Both boundaries remain symmetrical around the central line. ━━━━━━━━━━━━━━━━━━ 🎛 Manual Channel Width Adjustment The Channel Width setting allows users to define how sensitive the channel should be. Lower Channel Width values • move the boundaries closer to the central line • produce more frequent price touches • increase the number of bubbles • make the indicator more sensitive to smaller deviations Higher Channel Width values • create a wider channel • produce fewer boundary touches • highlight more substantial price deviations • reduce the number of bubbles displayed on the chart This allows the channel to be adapted to: • a specific trading instrument • the selected timeframe • current volatility conditions • the user’s preferred analytical approach The script does not impose a universal channel width. The user decides which degree of deviation is meaningful for the selected market. ━━━━━━━━━━━━━━━━━━ 🫧 How the Touch Bubbles Are Generated The indicator does not place a bubble on every bar that remains outside the channel. Instead, it marks the initial touch of a boundary. Upper Boundary Touch A red bubble appears when: • the current bar’s high reaches or exceeds the upper boundary • the previous bar’s high was below the previous upper-boundary value Lower Boundary Touch A green bubble appears when: • the current bar’s low reaches or falls below the lower boundary • the previous bar’s low was above the previous lower-boundary value This logic highlights the moment when price initially enters a deviation zone. It avoids placing a new bubble on every subsequent bar while price remains beyond the same boundary. The bubbles are positioned directly on the channel boundary rather than at the candle’s exact high or low. This makes it easier to see which calculated channel level was reached. ━━━━━━━━━━━━━━━━━━ ✦ Originality and Practical Usefulness Gaussian smoothing and mean absolute deviation are established mathematical concepts. The originality of Swing Reversion Zones does not come from mechanically combining unrelated indicators. It comes from the way its components are integrated into one consistent calculation framework. Within the script: A Gaussian-smoothed central trajectory is calculated across the available data. The channel scale is derived from the actual average distance between price and that trajectory. The user manually controls the final channel width through a single multiplier. Touch bubbles are calculated directly from the user-defined channel geometry. Changing the settings recalculates both the channel boundaries and the historical map of boundary touches. The bubbles are not produced by a separate signal indicator placed over the channel. Their position and frequency depend entirely on the current Gaussian trajectory, the measured price deviation and the selected Channel Width value. The result is an interactive analytical tool that allows users to define which price deviations should be considered significant for a particular market and timeframe. ━━━━━━━━━━━━━━━━━━ 📌 How to Use the Indicator After adding the indicator to a chart, begin with the default settings and observe how price interacts with the channel boundaries. The adjustment process can then be divided into two stages. Step 1. Adjust the Smoothing Change Smoothing Length until the central line reflects the type of price structure you want to analyse. A more responsive central line may be suitable for examining local fluctuations. A smoother central line may be more appropriate for evaluating deviations from a broader price structure. Step 2. Adjust the Channel Width After selecting the desired smoothing level, adjust Channel Width. The objective is not necessarily to make the boundaries touch every swing high and low. The objective is to define a deviation level that is meaningful for the selected instrument. A channel that is too narrow may produce many insignificant touches. A channel that is too wide may produce very few or no touch markers. Settings should be evaluated separately for different: • instruments • asset classes • timeframes • volatility regimes ━━━━━━━━━━━━━━━━━━ 🔍 Interpreting Boundary Touches A lower-boundary touch indicates that price has reached the selected negative deviation from the central trajectory. An upper-boundary touch indicates that price has reached the selected positive deviation. These areas may be useful for identifying potential mean-reversion conditions. However, reaching a boundary does not guarantee a reversal. During a strong directional move, price may: • repeatedly reach the same side of the channel • continue moving after a bubble appears • remain outside the boundary for several bars • return toward the central line only after a further expansion For this reason, bubbles should be treated as information about the current position of price relative to the channel, not as a complete trading system. Users may combine the touch markers with additional analysis such as: • higher-timeframe trend direction • swing-high and swing-low structure • support and resistance levels • candle behaviour following a touch • volume analysis • personal risk-management rules ━━━━━━━━━━━━━━━━━━ 🛠 Settings Smoothing Length Controls the Gaussian kernel width and the degree of smoothing applied to the central trajectory. Lower values increase responsiveness. Higher values create stronger smoothing. Channel Width Multiplies the mean absolute deviation between price and the central trajectory. This is the main setting for controlling the distance between the central line and the channel boundaries, as well as the frequency of touch bubbles. Source Defines the price series used in the calculation. The default source is the closing price. Users may select another available source, including open, high, low, HL2 or other standard price series. Style The visual settings allow users to adjust: • upper-boundary colour • lower-boundary colour • line thickness • bubble transparency ━━━━━━━━━━━━━━━━━━ ♻️ Repainting Behaviour Swing Reversion Zones intentionally uses repainting Gaussian smoothing. Historical points of the central trajectory are calculated using observations located on both sides of the corresponding point. As new bars become available, previously calculated values may change. The width of the channel is also based on the average error measured across the processed data. Changes in the available dataset may therefore affect the deviation value and the position of both boundaries. As new data appears, the following elements may change: • the central trajectory • the upper and lower boundaries • the position of historical bubbles • the number of historical bubbles • individual historical touch locations The indicator is also recalculated when the user changes: • the trading instrument • the timeframe • the price source • the smoothing length • the channel width Repainting is an intentional part of the indicator’s design. It is used to create a smoother historical representation of the price trajectory. Historical bubbles must not be interpreted as fixed past signals that were necessarily available in exactly the same form in real time. For the same reason, the visual history of the indicator should not be used to estimate historical profitability or as a substitute for proper strategy testing. ━━━━━━━━━━━━━━━━━━ 🔔 Alerts The script includes two alert conditions: Upper Channel Touch — price reaches the upper boundary Lower Channel Touch — price reaches the lower boundary Alert conditions are calculated relative to the current position of the channel. To reduce intrabar fluctuations, users may configure alerts to trigger only after the bar closes. However, waiting for bar close only reduces intrabar changes. It does not make the indicator non-repainting. The historical channel geometry may still change as new data becomes available. ━━━━━━━━━━━━━━━━━━ ⚠️ Limitations Swing Reversion Zones is an analytical indicator, not a trading strategy. It does not: • open or close positions • calculate stop-loss or profit targets • determine position size • account for commissions or slippage • calculate performance statistics • guarantee that price will return to the central trajectory • evaluate the quality of each individual trading opportunity Standard candlestick charts are recommended for interpretation. On non-standard chart types, OHLC values may be synthetic. As a result, boundary touches may not correspond to actual traded market prices. Users remain responsible for selecting the indicator settings, applying additional confirmation methods, defining entry and exit rules, and managing risk.Chỉ báocủa MarketStructureLab66390
Prev Day/Week VP Levels MADE BY ADAM Previous Day & Week Volume Profile Levels (POC / VAH / VAL) This indicator automatically plots the previous day's and previous week's volume profile levels — Point of Control (POC), Value Area High (VAH), and Value Area Low (VAL) — as clean horizontal levels extended to the right of the chart, replicating the look of manually drawn key levels. How it works Sessions are defined by a custom reset hour in a chosen timezone rather than midnight exchange time. The default is 19:00 New York (crypto perpetual sessions); set it to 18:00 for CME futures like MNQ/NQ to match the Globex daily open. Weeks run from the Sunday-evening session open through the Friday close. All profiles are calculated on a separate, configurable calculation timeframe (default 5-minute) through request.security, independent of the chart timeframe. This means the levels are identical on every chart resolution and remain visible even on a 1-minute chart, where the chart itself doesn't hold enough history to cover a full week. Each period's profile distributes bar volume across price rows (default 100), locates the POC as the highest-volume row, and expands the value area around it until it contains the configured share of total volume (default 70%). Once a day or week completes, its levels are drawn across the current period and stay fixed until the next rollover — the exact levels a trader would mark by hand at the start of each session. Features Previous day and previous week POC, VAH, VAL (each toggleable) Custom session reset hour and timezone (DST-safe) Configurable calculation timeframe, row count, and value area percentage Minimalist styling: line color, width, style (solid/dashed/dotted), plain text labels (pdaypoc, pweekvah, etc.) with adjustable offset and size No repainting: only completed periods are plotted Intended use Built for intraday traders who anchor their execution around prior-session value: value area rotations, POC retests, acceptance/rejection outside prior value, and confluence with order flow or options-derived levels.Chỉ báocủa adam45306
ATR CandleAn open-source version based on ATR Candle Size, for learning purposes only.Chỉ báocủa tbxcgj2
Uptrick: Vector Trail TrendIntroduction Uptrick: Vector Trail Trend (VTT) is an overlay tool that combines a velocity-projected trend line with an ATR-based adaptive trailing band to identify directional bias and trend reversals. A secondary momentum module layered on top flags statistically extreme momentum conditions that traders can use as dynamic take-profit references within the prevailing trend. The script also includes a configurable overlay presentation and an on-chart dashboard summarizing current trend state. Originality This script combines three distinct calculation layers that are not typically merged in a single publication, and each is included for a specific reason. The first layer builds a trend center from a smoothed moving average of price, then projects that line forward using a smoothed rate of change of the trend center itself, scaled by a user-defined projection factor. This produces a trend reference that leans in the direction of recent acceleration rather than simply lagging price, which is the basis used for the trailing band below it. The second layer wraps that projected trend center in an ATR-based band that only trails in the favorable direction and resets on a confirmed close beyond the opposite band, similar in mechanism to a ratcheting stop line. This layer is responsible for the directional flips and the up and down signals plotted on the chart. The third layer is independent of the first two and evaluates RSI relative to its own rolling mean and standard deviation, expressed as a Z-score. This is used to flag when momentum has reached a statistically extreme reading relative to its recent history, which the script surfaces as separate dynamic take-profit markers. This layer exists because trend direction and momentum exhaustion are different pieces of information, and combining them gives traders both a directional read and a separate overextension read without conflating the two into a single signal. The overlay is user-selectable between a gradient fill between price and the trail, a dual EMA trend ribbon, both together, or neither, so the visual presentation can be adjusted without changing the underlying trend or TP logic. Features Velocity-projected trend center using a smoothed moving average and a smoothed rate of change projection ATR-based adaptive trailing band with directional flip logic Confirmed-bar trend state calculation to avoid intrabar repainting of the trend flip Dynamic take-profit engine based on a Z-score of RSI relative to its own rolling mean and standard deviation Selectable TP marker style, cross or circle Up and down trend signal labels plotted at the trail Selectable overlay mode: vector gradient fill, trend ribbon, both, or none Adjustable gradient and ribbon transparency Optional candle coloring based on active trend direction Adjustable trail line width On-chart dashboard showing trend, signal, Z-score, TP state, distance from trail in ATR units, and active overlay mode Nine selectable dashboard positions Seven alert conditions: up signal, down signal, long dynamic TP, short dynamic TP, any trend signal, any dynamic TP, and all VTT signals combined Inputs Trend Settings: source, trend length, velocity smoothing length, vector projection factor. Trail Settings: ATR length, ATR multiplier. Dynamic TP Settings: show/hide dynamic TPs, TP marker style, momentum (RSI) length, Z-score length, TP extreme level threshold. Overlay: overlay style selection, gradient transparency, ribbon fast length, ribbon slow length, ribbon transparency. Visuals: show/hide up and down signals, candle coloring toggle, trail width. Dashboard: show/hide dashboard, dashboard position. How It Works / How to Use The trend center is calculated from a moving average of the chosen source, then projected forward using a smoothed measure of its own rate of change. An ATR-based band is built around this projected line and only moves in the direction favorable to the current trend, flipping only on a confirmed close beyond the opposite band. This flip is what produces the up and down signals and the trend color change. Once a trend is established, the script tracks RSI relative to its own recent mean and standard deviation. When this Z-score reaches the user-defined extreme level and then crosses back toward normal, a dynamic take-profit marker is plotted for the active trend, using the opposite color for visual distinction, indicating that momentum has cooled from an extreme reading. Traders can use the trail flips for directional bias and entries, and the dynamic TP markers as a secondary reference for potential exhaustion points within that trend. The overlay mode, transparency, candle coloring, and dashboard are all cosmetic and can be adjusted without affecting the underlying calculations. Conclusion Uptrick: Vector Trail Trend combines a velocity-projected trend line, an adaptive ATR trailing band, and a momentum Z-score take-profit layer into a single overlay tool, giving traders both a directional trend read and a separate momentum-exhaustion reference from one indicator. Disclaimer This script is provided for informational and educational purposes only and does not constitute financial advice. Past performance, whether shown historically or implied through the script's logic, does not guarantee future results. Always perform your own due diligence and risk management before making trading decisions. Chỉ báocủa Uptrick33 1.1 K
KC Sessions PRO [Asia, London & New York High/Low]Description KC Sessions PRO is a clean session-structure indicator designed to display the active trading ranges of the Asia, London, and New York sessions. The indicator tracks each enabled session’s developing high and low and presents the information using lightweight session boxes, high/low lines, compact labels, and a dashboard. Its main objective is to provide session context while keeping the chart readable and reducing unnecessary historical clutter. HOW IT WORKS During an active session, the script continuously updates that session’s high and low. When the session closes, its completed range can either be removed or retained temporarily, depending on the selected display mode. DISPLAY MODES • Clean — Displays active sessions only and removes completed session objects. • Standard — Displays active sessions and retains limited recent session history. • Pro — Displays active sessions with additional completed-session context. MAIN FEATURES • Asia, London, and New York session tracking • Developing session high and low • Optional session range boxes • Solid session-high lines • Dashed session-low lines • Compact A, L, and NY labels • Clean, Standard, and Pro display modes • Automatic removal of older chart objects • Adjustable completed-level extension • Configurable session time zone and hours • Compact active-session dashboard • Session open and close alert conditions DASHBOARD The dashboard displays: • Current active session • Active session high • Active session low • Selected display mode • Timeframe suitability status DEFAULT SESSION HOURS The default hours use the selected time zone: • Asia: 00:00–08:00 • London: 08:00–16:00 • New York: 13:00–21:00 Users should adjust these hours and the time zone where necessary for their instrument, broker, location, and daylight-saving requirements. RECOMMENDED USE This indicator is most useful on intraday charts, particularly: • 1-minute • 5-minute • 15-minute • 30-minute • 1-hour • 4-hour PRACTICAL APPLICATIONS KC Sessions PRO may be used to study: • Session range expansion • Intraday support and resistance • Breaks of session highs or lows • Volatility changes between trading sessions • London and New York overlap • Session-based market structure • Intraday liquidity context IMPORTANT LIMITATIONS • Session times depend on the selected time zone and user-defined session hours. • Different brokers and instruments may use different trading-day structures. • The displayed session high and low continue developing until the session closes. • Session levels should not be treated as automatic trade-entry signals. • The script does not predict future price direction or guarantee trading outcomes. This indicator is intended for educational and informational analysis only. It is not financial advice, a trading recommendation, or a guarantee of performance. Users should conduct their own analysis and apply appropriate risk management. Short Description: A clean intraday indicator that tracks Asia, London, and New York session ranges, developing highs/lows, limited session history, and active-session context. Release Notes INITIAL RELEASE — VERSION 2.1 • Added Asia, London, and New York session tracking • Added developing session highs and lows • Added Clean, Standard, and Pro display modes • Added session boxes and compact session labels • Added automatic historical-object cleanup • Added active-session dashboard • Added configurable timezone and session hours • Added session open and close alert conditions • Optimized default settings for a cleaner chart Chỉ báocủa Kelly_Carter126
RSI Divergence + EMA Trend FilterDescription: Divergence is one of the most discussed concepts in technical analysis and one of the most misapplied. The core idea is simple: when price makes a new high but the RSI makes a lower high, momentum is weakening even as price advances. That disconnect between price action and momentum is what divergence measures — and it often precedes reversals before price itself confirms the change in direction. This strategy formalizes that concept into a rule-based, backtestable system with two components: RSI divergence detection and an EMA trend filter that determines which divergences to act on. What divergence actually measures RSI measures the speed and magnitude of price changes. When price reaches a new swing high but RSI fails to reach a correspondingly higher reading, it means the buying pressure behind the new high was weaker than the buying pressure behind the previous high. The market got to a higher price but required less momentum to do it — which suggests the move is losing conviction. Bearish divergence (price higher, RSI lower) signals potential exhaustion in an uptrend. Bullish divergence (price lower, RSI higher) signals potential exhaustion in a downtrend. Important: divergence is a momentum signal, not a reversal guarantee. Price can continue making new highs with weakening RSI for a significant period before actually reversing. This is why divergence signals work best when combined with a trend filter that identifies the broader market context. The EMA filter The 200 EMA defines the dominant trend regime. Bearish divergence signals — where momentum is weakening on the upside — are only acted on when price is below the 200 EMA, meaning the broader trend is already bearish and divergence represents a potential resumption of that trend after a counter-trend bounce. Bullish divergence signals are only acted on when price is above the 200 EMA, where they represent potential continuations of the dominant uptrend after a pullback with improving momentum. This filter deliberately reduces the total number of signals. Many valid divergences occur against the dominant trend and produce short-lived reversals that reverse again quickly. By requiring trend alignment, the strategy trades fewer setups but acts on the ones with a higher probability of following through. How divergence is detected The strategy identifies swing highs and swing lows using a lookback period — the number of bars on each side of a pivot that must be lower (for a high) or higher (for a low) to qualify as a genuine swing point. When two consecutive swing highs show price making a higher high but RSI making a lower high, bearish divergence is flagged. When two consecutive swing lows show price making a lower low but RSI making a higher low, bullish divergence is flagged. The lookback length is the most important input to tune. A shorter lookback detects more swing points and generates more signals, but many will be minor pivots in the context of noise. A longer lookback requires more significant swing points and generates fewer, higher-quality signals. On daily charts, a lookback of 5 works well. On lower timeframes, 3 to 4 is more appropriate. Exits Positions exit at an ATR-based stop-loss and a fixed ATR-based take-profit. The stop is placed beyond the swing point that generated the divergence signal — for a bearish divergence, the stop sits above the swing high; for a bullish divergence, below the swing low. This is intentional: if price breaks through the very level that defined the divergence, the signal is invalidated regardless of what RSI was doing. The take-profit is set at 2x ATR to maintain a positive reward-to-risk ratio across the system. What to evaluate in backtesting Look at the signal distribution across different market environments. Divergence strategies tend to perform differently in trending versus ranging markets — in strong trending environments, bearish divergences against the dominant trend will produce many false signals even with the EMA filter. Look at whether the EMA filter is doing real work by temporarily disabling it and comparing signal quality. Check average trade duration — divergence signals that take too long to play out often give back open profit before the take-profit level is reached. This is not a high-frequency strategy. On daily charts with a 5-bar lookback, signals may appear only a few times per month on a given instrument. That frequency is appropriate — divergence setups require specific conditions to form and should not be forced. Shared for educational purposes and discussion. This is not investment advice. Backtest on your own instruments and timeframes before drawing conclusions about expected performance.Chiến lượccủa AIScripts10
Multi-Timeframe Squeeze Board LiteWhat it shows Multi-Timeframe Squeeze Board — Lite answers one question at a glance: "Where is this symbol compressed, and which way is momentum leaning, on every timeframe that matters?" For the chart's symbol it displays a compact table with one row per timeframe — 15m, 1h, 4h, Daily, Weekly — and two readings per row: - Sqz — the TTM Squeeze compression state as a colored dot, using the standard three-level cascade: orange = high squeeze (deepest compression), red = mid squeeze, black = low squeeze, green = no squeeze (volatility released / normal). - Mom — the squeeze momentum oscillator as a colored arrow using the classic 4-color scheme: aqua = positive and rising, blue = positive but falling, yellow = negative but rising, red = negative and falling. The arrow points up when momentum is increasing bar-over-bar and down when it is decreasing. A stacked squeeze (orange/red dots on several adjacent timeframes) marks a market coiling across horizons; the momentum colors tell you which side the pressure is building on. How it works Each row runs the full TTM Squeeze calculation on its own timeframe via request.security() with lookahead = barmerge.lookahead_off (no future data, ever): 1. Bollinger Bands: SMA(close, 20) basis, 2.0 × population standard deviation. 2. Keltner Channels: the same SMA(close, 20) basis, with band width = SMA of True Range over 20 bars (simple average of TR — not Wilder's ATR) at three multipliers: 1.0, 1.5, 2.0. 3. A squeeze is on when the Bollinger Bands sit fully inside the Keltner Channel on both sides. The narrower the Keltner band that still contains the BB, the deeper the compression — hence the 1.0-multiplier band defines the high squeeze, 1.5 the mid, 2.0 the low. 4. Momentum is the linear regression of price's deviation from the average of the Donchian midline and the SMA, over the same 20 bars. By default the board evaluates confirmed bars only: every row shows the last fully closed bar of its timeframe, so a dot or arrow never changes after it appears. See Limitations for the tradeoff. Inputs - Squeeze length — lookback for BB, KC and momentum (default 20, the canonical TTM setting). - Confirmed HTF bars only — ON (default): stable, non-repainting readings that lag up to one bar of each row's timeframe. OFF: rows track the still-forming higher-timeframe bar — more current, but the reading can flip until that bar closes. - Table position / Table size — where the board sits and how large it renders. How to use it Apply it to a 15m chart (or lower) so all five rows populate. Scan the Sqz column top-to-bottom: multiple orange/red dots stacked across timeframes indicate multi-horizon compression — historically the precondition for expansion moves. Then read the Mom column for directional lean while the compression resolves. The board is a context tool: it tells you where energy is stored, not when or in which direction it must release. Limitations — please read - Confirmed-bar lag: with the default non-repainting mode, the Weekly row updates once per week, the Daily row once per day, etc. That is the honest cost of stability. Turning the toggle off shows the live forming bar instead, and those readings can change until the bar closes. - Rows below the chart's timeframe show "–": Pine's request.security() cannot reliably reconstruct lower-timeframe series, so instead of showing a possibly wrong dot the board declines to show one. Use a 15m chart to see everything. - A squeeze has no direction. Compression means stored energy, not a buy or sell signal. The momentum color is a lean, not a prediction. - Warm-up: each timeframe needs about 20 bars of history before its row populates (shown as "·" until then). This board covers one symbol — the chart's. Chỉ báocủa technical_trading_academy8
Ichimoku Cloud Thickness SpectrumOverview Ichimoku Cloud Thickness Spectrum is an overlay for studying the geometry and relative thickness of the projected Ichimoku cloud. It plots the classical Tenkan-sen, Kijun-sen, Senkou Span A, Senkou Span B, and an optional Chikou Span, then adds a configurable research layer derived only from the distance and relationship between the two Senkou spans. The script is designed to make three questions easier to inspect: - How wide is the projected cloud in a unit suited to the current instrument? - How unusual is that width compared with the cloud's own recent history? - Is the smoothed cloud thickness expanding, contracting, or comparatively stable? This is a context and visualization tool. It does not generate buy or sell instructions, forecasts, targets, stops, position sizing, or performance claims. Original contribution Cloud thickness is a known Ichimoku concept. The original contribution of this implementation is the integrated workflow used to transform raw Span A/B distance into a configurable research display: 1. Selectable ATR, percentage, or raw-price normalization. 2. Rolling empirical percentile ranking of the selected thickness measure. 3. Percentile-weighted cloud opacity and an optional dense inner core. 4. A stabilized expansion/contraction spine with a near-zero denominator floor and release-ratio hysteresis. 5. Confirmed thin-cloud seams filtered by thin-state membership, two-sided prominence, and minimum spacing. 6. Directional projected-cloud twist markers. 7. Separate handling of the newly calculated forward cloud and the historically shifted cloud aligned with the current price bar. 8. A bilingual confirmed/live readout, confirmed-bar alerts, and Data Window diagnostics. The classical Ichimoku formulas are standard, widely known calculations. The percentile, motion-state, seam-filtering, visualization, readout, and alert logic were implemented for this script. No source code from another Community Script is reused. Core calculations - Tenkan-sen: midpoint of the highest high and lowest low over the Conversion length. - Kijun-sen: midpoint of the highest high and lowest low over the Base length. - Senkou Span A: average of Tenkan-sen and Kijun-sen. - Senkou Span B: midpoint of the highest high and lowest low over the Span B length. - Raw cloud thickness: absolute distance between Senkou Span A and Senkou Span B. - Cloud midpoint: average of Senkou Span A and Senkou Span B. Thickness modes and percentile ranking - ATR: raw cloud thickness divided by ATR. This is the default and relates cloud width to recent price range. - Percent: raw cloud thickness divided by the absolute close, multiplied by 100. - Raw: the unnormalized price distance between Span A and Span B. The selected measure is ranked against its own rolling history with a percent-rank calculation. A reading near 10 is relatively thin within the selected lookback, while a reading near 90 is relatively thick. The result is specific to the symbol, timeframe, settings, and available history; it is not a universal market-strength score. Stabilized expansion and contraction The selected thickness measure is smoothed with an EMA. A one-bar percentage change is then calculated. Near a cloud twist, Span A and Span B can converge and the previous thickness can approach zero, which can make an unrestricted percentage change unstable. To reduce this effect, the denominator cannot fall below a configurable fraction of a slower EMA baseline. The state classifier also uses release-ratio hysteresis. Entry into expansion or contraction requires the main sensitivity threshold, while release from an existing state uses a smaller configurable threshold. This reduces bar-to-bar color chatter. The state uses the previous bar and does not rely on intrabar-only persistent memory. Visual interpretation - Teal cloud: Senkou Span A is at or above Senkou Span B. - Red cloud: Senkou Span A is below Senkou Span B. - More transparent cloud: lower thickness percentile. - More visible cloud: higher thickness percentile. - Dense inner core: optional emphasis when thickness percentile is above the selected threshold. - Blue midpoint spine: thickness is in an expanding state. - Purple midpoint spine: thickness is in a contracting state. - Gray midpoint spine: thickness motion is inside the release threshold. - Yellow upward/downward triangle: confirmed bullish/bearish projected-cloud twist. - Small pink X: confirmed local thin-cloud seam that passed the thin-state, prominence, and spacing filters. The cloud opacity and inner core encode relative thickness only. They do not guarantee support, resistance, continuation, reversal, or breakout behavior. Filtered thin-cloud seams A thin seam is not every low-thickness bar. It must be a confirmed local minimum in the thickness percentile, remain at or below the user-defined thin threshold, rebound by at least the selected prominence on both sides, and pass the minimum-spacing filter. The pivot becomes known only after the selected number of right-side bars has closed. By default, a marker is not placed to the left of the bar where confirmation became available. The optional Allow seam placement before confirmation setting can place the marker at the original pivot-projected cloud position after confirmation. This changes the visual location only and does not make the event available earlier. Projected cloud versus current aligned cloud The newly calculated Span A and Span B values are displayed forward by the selected displacement. This positive offset shifts calculations made from current and historical bars into future chart positions; it does not access future market data. Price-context calculations use a different alignment. They reference the historically shifted spans that are actually visible at the current price bar. Optional inside-cloud highlighting and current-cloud transition alerts therefore do not compare current price with the newly calculated cloud plotted in the future. Forward readout, alerts, and research outputs The three-line readout displays the thickness state and percentile, the selected normalized thickness value and motion state, and the future-cloud direction with Live or Confirmed status. English is the default. Japanese changes the readout, hover tooltip, and combined dynamic alert messages; input names and tooltips are bilingual. Use confirmed values in readout is enabled by default. While the latest realtime bar is open, the label uses the previous closed bar. Once the latest bar is confirmed, it uses that bar. Users can disable the setting to inspect the open realtime bar, in which case the label shows Live and may change until close. Confirmed-bar alert conditions are available for projected twists, thin/thick state transitions, current-cloud position transitions, expansion/contraction changes, and filtered thin seams. A combined bilingual alert is also available through Any alert() function call. Additional raw, normalized, percentile, motion, seam, current-cloud, direction, and state values are provided in the Data Window. Realtime behavior and limitations The script does not use request.security(), lookahead, or future bars. On an open realtime bar, Tenkan-sen, Kijun-sen, the projected spans, cloud opacity, and motion state can update as the bar's high, low, and close change. Confirmed historical values do not use intrabar-only memory. The supplied alert conditions are evaluated on confirmed bars, and the combined alert() call uses once-per-bar-close frequency. Percentile readings require sufficient history and can show a warming-up state. Results depend on the symbol, timeframe, Ichimoku lengths, normalization basis, percentile lookback, and available data. Non-time-based charts and sparse datasets may behave differently from standard time-based candles. A thick cloud is not automatically strong support or resistance. A thin or contracting cloud is not a breakout prediction. This script provides research context and should be combined with the user's own analysis and risk process. 日本語概要 Ichimoku Cloud Thickness Spectrumは、一目均衡表の将来雲について、方向だけでなく、厚み、履歴内の相対順位、拡大・収縮状態を研究するためのオーバーレイ型インジケーターです。転換線、基準線、先行スパン1・2、任意の遅行スパンを表示し、追加分析はすべて先行スパン1と2の距離および関係から算出します。 主な特徴 - 雲の厚みをATR比率、価格比率、価格差から選択可能。 - 選択した厚みを直近履歴内のパーセンタイルへ変換。 - 厚み順位を雲の透明度と任意の高密度インナーコアへ反映。 - ゼロ近傍の分母下限とヒステリシスを備えた拡大・収縮中心線。 - 薄い状態、左右プロミネンス、最小間隔を満たした確認済み局所薄化点。 - 上向き・下向きを分けた確認済み将来雲ツイスト。 - 将来へ描画する新規計算雲と、現在価格バーへ整列した過去計算雲を分離。 - 英語・日本語を切り替えられる将来ラベル、確定足アラート、データウィンドウ研究値。 雲の厚みという概念自体は既知です。本実装の差異は、生の雲幅を正規化し、履歴順位化し、厚みの動きを安定化し、薄化点を確認・選別し、それらを一貫した視覚表現と研究出力へ統合している点です。標準一目均衡表の計算式は広く知られた古典計算であり、追加した順位化、状態判定、薄化点フィルター、表示、ラベル、アラートのロジックは本スクリプト用に実装しています。他のCommunity Scriptのソースコードは再利用していません。 表示の読み方 - 青緑の雲: 先行スパン1が先行スパン2以上。 - 赤の雲: 先行スパン1が先行スパン2未満。 - 透明度が高い雲: 厚み順位が低い。 - 濃い雲とインナーコア: 厚み順位が高い。 - 青の中心線: 厚みが拡大状態。 - 紫の中心線: 厚みが収縮状態。 - 灰色の中心線: 安定状態。 - 黄色の三角: 確認済みの上向き・下向き将来雲ツイスト。 - 小さなピンクのX: 条件を満たした確認済み局所薄化点。 厚み順位は銘柄、時間足、設定、参照期間、利用可能な履歴に依存する相対値です。雲の濃さやインナーコアは支持抵抗の保証ではありません。 確認、シフト、ライブ動作 将来雲は、現在および過去バーから計算した先行スパンを正のoffsetで将来位置へ描画したもので、未来データを取得していません。現在価格との関係には、現在バー上に実際に整列している過去計算の先行スパンを使用します。 薄化点は右側に指定本数の確定バーを必要とするため、認識に意図的な遅延があります。初期設定では確認可能になったバーより左側へ表示しません。任意設定で元の投影位置へ表示する場合も、認識自体は確認後です。 未確定リアルタイムバーでは、高値・安値・終値の更新に伴い、転換線、基準線、先行スパン、雲の透明度、拡大・収縮状態が終値確定まで変化する場合があります。将来ラベルは初期設定で確定値を使用し、用意したアラートは確定足で判定します。 本インジケーターは研究・可視化ツールです。売買指示、将来予測、目標価格、損切り、ポジションサイズ、成績統計、投資助言を提供しません。厚い雲を必ず強い支持抵抗、薄い雲や収縮中の雲を必ずブレイクする状態とは定義していません。Chỉ báocủa SG_Group6
Median Cascade Trend [BackQuant]Median Cascade Trend Overview Median Cascade Trend is a noise-resistant trend-following indicator that combines multiple causal median filters , an Ehlers-style two-pole Super Smoother , and a configurable chop-gating system . Its purpose is to identify meaningful directional structure while rejecting the types of price movement that frequently cause conventional moving averages to whipsaw: Single-bar spikes Short-lived price shocks Irregular wicks Low-efficiency sideways movement Weak slopes that do not represent genuine directional progress The indicator processes price in three distinct stages: A median-filter cascade removes impulsive and short-duration noise. A two-pole low-pass filter smooths the remaining structural signal. A chop gate decides whether a change in direction is strong enough to update the active trend state. This creates a trend line that is intentionally more selective than a standard moving average. The line itself can continue evolving, but trend-state changes are only accepted when the underlying movement passes the chosen quality tests. The result is a system that separates: The estimated trend line The raw direction of that line The confirmed trend regime That distinction is important. The indicator does not assume that every small turn in a smoothed line represents a valid trend reversal. Core idea Most trend filters are built around linear averaging. They combine historical prices using fixed or exponentially decaying weights. Examples include: SMA EMA WMA HMA DEMA These filters are effective for general smoothing, but they have a weakness: a single extreme observation can influence the output immediately. If one bar produces a large wick or temporary price shock, a moving average will usually be pulled toward that value because it includes the magnitude of every observation. A median filter behaves differently. Instead of averaging the values inside a window, it sorts them and selects the middle observation. This makes it highly resistant to isolated extremes. Median Cascade Trend uses this property repeatedly before applying traditional low-pass smoothing. The central idea is: Remove impulsive noise first. Smooth the cleaned signal second. Confirm direction only when the movement is efficient or sufficiently steep. This ordering is deliberate. Smoothing a noisy series and filtering noise before smoothing are not the same thing. Where median filtering comes from Median filters are widely used in digital signal processing, image processing, and engineering. One of their best-known applications is the removal of impulse noise , sometimes called salt-and-pepper noise in image processing. Impulse noise consists of isolated extreme observations that are not representative of the surrounding signal. In market data, comparable events include: Temporary liquidity gaps Single-bar stop runs Erroneous prints Sharp wick reversals News spikes that immediately retrace A linear smoother such as an SMA or EMA cannot distinguish between an important sustained move and an isolated outlier. Both are included according to their numerical magnitude. A median filter is nonlinear. It selects the central-ranked value rather than calculating an arithmetic mean. For example, consider five observations: 100 101 102 103 140 The average is: 109.2 The median is: 102 The isolated value at 140 significantly distorts the average but has almost no effect on the median. This is why median filtering is especially useful when the objective is to preserve structural turns while rejecting isolated noise. What makes a median filter nonlinear A normal moving average can be represented as a weighted sum of its inputs. A median filter cannot. Its output depends on the ordering of observations, not their arithmetic combination. This makes it a nonlinear filter. That has several important consequences: Outliers have limited influence. Edges and structural shifts can be preserved more cleanly. The response is not equivalent to ordinary low-pass averaging. The filter may hold a value until enough observations confirm a change. In trading terms, the median filter often behaves more like a structural selector than a conventional average. What “causal” means The median stages in this indicator are causal. A causal filter uses: The current bar Past bars It does not use future observations. This matters because many visually smooth filtering methods can only produce their best result by centering the calculation around the current point, which requires future data. This script does not do that. Every value is calculated from information available at that bar, making the filter suitable for live use. Why use a cascade of median filters A single median filter can remove isolated spikes, but noise does not always occur as one extreme bar. It can appear as: Two-bar shocks Short bursts of alternating movement Small clusters of irregular candles Residual distortion left after the first filtering pass A cascade applies multiple median stages sequentially: Stage 1 processes the original source. Stage 2 processes the output of Stage 1. Stage 3 processes the output of Stage 2. Each stage removes a different layer of short-duration instability. The process is similar to progressively cleaning a signal: The first stage removes obvious impulse noise. The second stage removes remaining short-term irregularity. The third stage produces a more stable structural series before low-pass smoothing. Median Stage 1 The first median stage is intended to reject isolated one-bar disturbances. With a short setting such as 3: The filter remains responsive. Single-bar spikes are strongly suppressed. Most genuine multi-bar movement remains visible. This is the most tactical stage. Median Stage 2 The second stage receives an already-cleaned input. Its role is to remove: Short-duration residual noise Small alternating movements Irregularity that survived the first stage A slightly longer setting such as 5 creates stronger structural consistency. Median Stage 3 The third stage provides the final nonlinear cleaning pass. With a longer setting such as 7: The output becomes more stable. Short-lived reversals are reduced. Only more persistent changes are passed into the low-pass stage. This is the most conservative median stage. Cascade Stages input The user can select how many median stages are active: 1 stage: fastest and most responsive 2 stages: balanced noise rejection 3 stages: strongest impulse-noise suppression The unused stages are still calculated internally, but the selected stage determines which output is sent into the Super Smoother. Why cascade instead of one very long median Applying several shorter filters is not always equivalent to applying one very long median filter. A long median window can: Delay structural changes heavily Flatten shorter trend legs Become insensitive to local turns A cascade allows the filtering process to be distributed across stages. This provides greater control over: How aggressively isolated noise is removed How much short-duration movement survives How smooth the final structural input becomes It also lets users build a progression such as 3, 5, and 7 rather than applying one blunt window. The low-pass stage After the median cascade, the signal is passed into a two-pole Super Smoother . The median cascade removes nonlinear impulse noise, but its output can still contain: Small step changes Residual high-frequency movement Sharp transitions caused by median replacement The Super Smoother converts that cleaned but potentially stepped series into a smoother trend line. This creates a hybrid filtering system: Nonlinear median filtering for outlier rejection Recursive low-pass filtering for smooth trend extraction These components solve different problems. Where the Super Smoother comes from The Super Smoother is associated with John F. Ehlers’ application of digital signal processing techniques to financial markets. It is based on the behavior of a two-pole low-pass filter and is designed to suppress high-frequency components more effectively than many conventional moving averages. Traditional moving averages are simple smoothers, but they are not necessarily optimized as frequency-selective filters. The Super Smoother uses recursively calculated coefficients derived from: Exponential decay Trigonometric terms A selected cutoff period The objective is to reduce high-frequency market noise while retaining lower-frequency directional structure. What a low-pass filter does A low-pass filter allows slow-moving components of a signal to pass while reducing fast-moving components. In market terms: Slow components represent broader trend structure. Fast components represent short-term noise, rapid oscillation, and microstructure disturbance. The Low-Pass Length determines the separation. Lower values: Allow more short-term movement through. React faster. Produce more turns. Higher values: Reject more high-frequency movement. Produce a smoother trend line. Respond later to structural changes. Why use a two-pole filter The number of poles broadly describes the order and steepness of a filter. A two-pole filter generally provides: Stronger attenuation of high-frequency noise than a one-pole filter. A smoother output. A more defined frequency response. It also uses prior filter outputs recursively, allowing substantial smoothing without requiring an extremely long direct averaging window. The full signal-processing chain The calculation can be understood as: Raw price source Median Stage 1 Optional Median Stage 2 Optional Median Stage 3 Two-pole Super Smoother Direction measurement Chop-quality validation Persistent trend state Each layer has a distinct purpose. Median cascade Rejects isolated and short-lived noise. Super Smoother Reduces the remaining high-frequency variation. Direction logic Determines whether the final line is rising or falling. Chop gate Determines whether that directional change is trustworthy enough to update the confirmed trend. Trend direction calculation The raw direction is determined by comparing the current trend line with its value several bars ago: Bullish if trendLine > trendLine Bearish if trendLine < trendLine Neutral if equal The Direction Lookback controls how much movement is required before the line is classified as rising or falling. A one-bar comparison is extremely responsive but can detect tiny slope changes. A longer comparison: Measures movement across a wider interval. Reduces sensitivity to one-bar flattening. Produces more stable raw direction. Raw trend versus confirmed trend One of the most important design choices is that the script separates: Raw trend Confirmed trend The raw trend reflects the current direction of the filtered line. The confirmed trend is persistent and changes only when: The raw trend points in a new direction. The chop gate is open. If the line turns but the gate is closed: The active trend state remains unchanged. The attempted flip can optionally be displayed as blocked. This prevents every small line turn from immediately becoming a regime reversal. Why a chop filter is needed Even an advanced smoother can turn repeatedly during sideways markets. Smoothing reduces noise, but it does not determine whether movement is: Directional Efficient Large enough relative to volatility A line can move upward and downward in a range while making almost no net progress. The chop gate addresses this by evaluating two separate properties: Directional efficiency ATR-normalized slope Efficiency Ratio The first gate component measures how efficiently the trend line has moved over a selected window. The calculation compares: Net movement Total movement Net movement is: |trendLine - trendLine | Total movement is: Sum of |bar-to-bar changes in trendLine| The Efficiency Ratio is: Efficiency = Net Movement / Total Movement The result ranges approximately from 0 to 1. Efficiency near 1 The line has moved mostly in one direction. Example: It advanced 10 units. Its total path was approximately 11 units. This indicates a clean directional move. Efficiency near 0 The line has moved back and forth without achieving much net progress. Example: It travelled 20 units in total. But ended only 1 unit from where it started. This indicates chop. Where the Efficiency Ratio comes from The Efficiency Ratio is commonly associated with Perry Kaufman’s work on adaptive market analysis and the Kaufman Adaptive Moving Average. Its purpose is to distinguish directional movement from noisy movement. It does not measure the size of a move alone. It measures the quality of the path. This makes it highly suitable as a trend gate. A market can be volatile but inefficient. It can move aggressively in both directions and still make little progress. The Efficiency Ratio helps identify that distinction. Minimum Efficiency The Minimum Efficiency input determines the directional quality required for the efficiency condition to pass. Lower values: Allow more irregular movement. Open the gate more frequently. Produce earlier but noisier trend changes. Higher values: Require cleaner directional travel. Block more sideways flips. Produce fewer but more selective regime changes. ATR-Normalized Slope The second gate component measures how large the trend-line movement is relative to current market volatility. It calculates: |trendLine - trendLine | / ATR This converts the line’s movement into ATR units. Without normalization, a slope of 10 points could be: Large for one instrument Negligible for another Large in a quiet regime Small during extreme volatility ATR normalization makes the slope more comparable across assets and regimes. What normalized slope measures The Efficiency Ratio asks: Was the movement directionally clean? ATR-normalized slope asks: Was the movement large enough to matter? These are different questions. A move can be highly efficient but extremely small. For example: A perfectly smooth drift of only 0.02 ATR may not justify a new trend regime. A move can also be large but inefficient: A violent range may travel several ATRs while repeatedly reversing. Using both filters gives a more complete view of trend quality. Minimum ATR-Normalized Slope The Minimum ATR-Normalized Slope defines the movement threshold. Lower values: Accept weaker slopes. React sooner. Allow more low-energy flips. Higher values: Require stronger displacement. Reduce weak trend transitions. Delay signals until movement becomes more meaningful. Gate modes The indicator provides four chop-gate modes. Efficiency Ratio Only directional efficiency is required. Best suited for users who care primarily about whether movement is clean, regardless of its exact magnitude. ATR-Normalized Slope Only slope strength is required. Best suited for users who want movement to exceed a volatility-adjusted threshold, even if the path is not perfectly efficient. Both Both conditions must pass: Efficiency must be high enough. Slope must be strong enough. This is the strictest mode and generally provides the strongest chop rejection. Either Only one condition must pass. This is more permissive: A very clean slow trend may pass through efficiency. A powerful but less orderly move may pass through slope. It provides a balance between responsiveness and filtering. Gate behavior When the gate is open: A new raw direction can update the trend state. Bullish and bearish flips can be confirmed. When the gate is closed: The previous confirmed trend persists. Attempted changes are blocked. The display can dim, turn neutral, or hide. This means the indicator behaves like a regime-holding system during chop. It does not constantly reset to neutral. It retains the last confirmed direction until sufficient evidence supports a new one. Blocked flips A blocked flip occurs when: The filtered line attempts to change direction. The attempted direction differs from the confirmed trend. The chop gate is closed. The raw direction has just changed. These can optionally be displayed as small X markers. Blocked flips are useful because they show: Where a basic slope indicator would have reversed. Where the chop filter rejected that reversal. How much signal noise the gate is removing. They are not trade signals. They are diagnostic information. Trend persistence The trend variable is persistent. Once bullish: It remains bullish until a valid bearish change passes the gate. Once bearish: It remains bearish until a valid bullish change passes the gate. This persistence is central to the design. The indicator is not merely coloring every local slope. It is maintaining a confirmed market regime. Display modes when the gate is closed The indicator offers three ways to display gated conditions. Dim The current trend color remains visible but becomes transparent. This communicates: The last confirmed trend is still active. Current conditions are not strong enough to confirm a new direction. This is useful when you want regime continuity without overstating conviction. Neutral The trend line and candles switch to the selected gate color. This communicates: The directional regime is being withheld. Current conditions are considered non-trending or uncertain. Hide The trend line disappears while the gate is closed. This is the strictest visual mode. It communicates: No actionable trend state should be displayed during the gated condition. Trend line coloring The base color is determined by the confirmed trend: Bullish trend uses the long color. Bearish trend uses the short color. Uninitialized state uses gray. The gate display can then modify the final presentation. This allows the chart to show: Direction Confirmation status Chop-filter activity without needing a separate panel. Gradient fill The indicator fills the area between price and the trend line. When price is above the trend line: A bullish gradient is displayed. When price is below the trend line: A bearish gradient is displayed. The fill is stronger near the trend line and fades toward price. This emphasizes the trend line as the structural reference. The fill color follows the gate display state: Full trend color when active Dimmed during a closed gate in Dim mode Neutral when configured Hidden when the trend line is hidden Trend glow A soft glow is created around the filtered line using a small ATR-scaled distance. The glow width is: ATR(14) × 0.06 Using ATR ensures the glow remains visually proportional across assets and price scales. The glow does not affect the calculation. It improves readability and reinforces the line as the central structural output. Candle coloring Candles can be colored using the confirmed trend state. When the gate is open: Bull trend produces bullish candles. Bear trend produces bearish candles. When the gate is closed: Dim mode fades the existing trend color. Neutral mode uses the gate color. Hide mode removes the candle override. This gives an immediate full-chart view of both trend and gate status. Signal logic Signals only occur when the confirmed trend changes. Bullish flip A bullish signal requires: The active trend becomes bullish. The previous trend was bearish. The gate accepted the change. Bearish flip A bearish signal requires: The active trend becomes bearish. The previous trend was bullish. The gate accepted the change. This is more selective than simply detecting a change in line slope. How to interpret the indicator Bullish confirmed regime A bullish regime means: The median-filtered and low-pass-smoothed trend line is rising. The move satisfied the selected chop-filter conditions when the regime changed. The last accepted direction remains bullish. Bearish confirmed regime A bearish regime means: The final trend line is falling. The bearish change passed the selected quality gate. The last accepted direction remains bearish. Gate closed in an existing trend This means: The market is no longer moving with sufficient efficiency or slope. A new reversal cannot currently be confirmed. The previous regime remains stored. This often occurs during: Consolidation Pullbacks Low-volatility drift Transition phases Repeated blocked flips Repeated blocked changes suggest: The filtered line is oscillating. Directional quality is weak. A normal trend-following system would likely be whipsawing. This is exactly the environment the gate is designed to avoid. How to use it in practice 1. Directional regime filter Use the confirmed trend to filter other setups: Favor long trades during bullish regimes. Favor short trades during bearish regimes. Reduce activity when the gate is closed. 2. Trend-following entries Bullish and bearish flips can be used as directional entry triggers, especially when confirmed by: Price structure Breakouts Volume expansion Higher-timeframe alignment 3. Pullback framework During an established trend: Price returning toward the trend line may represent a pullback. If the gate remains closed but the trend does not flip, the move may be consolidation rather than reversal. If the opposite direction eventually passes the gate, the regime has changed more meaningfully. 4. Chop avoidance The most direct use is avoiding repeated entries during low-quality conditions. When the display is dim, neutral, or hidden: Reduce confidence in new trend signals. Wait for efficiency or slope to recover. 5. Diagnostic comparison Enable blocked flips to see how often the raw trend attempts to reverse without confirmation. This helps tune: Efficiency threshold Slope threshold Gate mode Input guide Source Selects the price series used by the median cascade. Close is the standard choice. Alternatives such as hl2 or hlc3 may produce a slightly smoother structural input. Cascade Stages Controls how many median filters are used. 1: responsive 2: balanced 3: strongest noise rejection Median Stage Lengths Control the window used at each stage. Shorter values: Preserve responsiveness. Remove only very short-duration noise. Longer values: Produce stronger structural filtering. Delay shorter turns. Low-Pass Length Controls the two-pole Super Smoother. Lower: Faster More reactive Higher: Smoother More conservative Direction Lookback Controls how far back the current line is compared when determining raw direction. Lower: Faster slope changes Higher: More stable directional measurement Efficiency Length Controls the window used to measure net movement versus total path movement. Shorter: More responsive efficiency reading More sensitive to recent chop Longer: More stable directional-quality assessment Minimum Efficiency Controls how clean the directional path must be. Higher values make the gate stricter. Slope Length Controls the interval across which trend-line movement is measured. Slope ATR Length Controls the ATR baseline used to normalize slope. Minimum ATR-Normalized Slope Controls the minimum volatility-adjusted displacement required. Higher values require stronger movement. Tuning examples Faster trend configuration 1 or 2 median stages Short median windows Lower Super Smoother length Direction Lookback of 1 or 2 Either gate mode Lower efficiency and slope thresholds Balanced configuration 2 or 3 median stages Progressive windows such as 3, 5, 7 Moderate Super Smoother length Both gate mode Moderate thresholds Conservative configuration 3 stages Longer median windows Higher Super Smoother length Longer Direction Lookback Both gate mode Higher minimum efficiency and slope How this differs from a normal moving average A standard moving average: Uses linear averaging. Responds directly to outlier magnitude. Changes direction whenever its slope changes. Median Cascade Trend: Uses nonlinear outlier-resistant preprocessing. Applies a proper recursive low-pass stage. Separates raw direction from confirmed regime. Blocks changes during inefficient or weak movement. How this differs from a normal median filter A basic median filter only removes impulse noise. This indicator extends the idea by adding: Multiple median stages Low-pass smoothing Direction measurement Efficiency gating Volatility-normalized slope gating Persistent trend states Signals and alerts It is not simply a median-smoothed line. It is a complete trend-regime system built on median preprocessing. How this differs from a Supertrend A Supertrend uses ATR bands around price and changes state when price crosses the trailing boundary. Median Cascade Trend does not use a volatility band to define direction. Instead: Direction comes from the slope of the filtered trend line. ATR is used only to normalize slope and scale visuals. Trend changes are controlled by movement quality rather than price crossing a stop band. Strengths Strong rejection of isolated price spikes Preserves broader structural movement Combines nonlinear and linear filtering Separates raw turns from confirmed trend changes Configurable chop rejection Volatility-normalized slope testing Persistent directional regimes Blocked-flip diagnostics Fully causal calculation Limitations Strong filtering can delay genuine reversals. Long median windows may suppress shorter trend legs. Strict gate settings can hold the previous regime too long. Loose gate settings reduce the benefit of chop filtering. Median filters can produce stepped transitions before low-pass smoothing. The indicator remains reactive rather than predictive. Best use cases Median Cascade Trend is particularly suited for: Trend filtering in noisy markets Reducing false reversals caused by wicks Swing-trading regime identification Filtering entries from faster systems Dynamic trend-structure visualization Avoiding sideways-market whipsaws It can be applied across: Equities Indices Futures Forex Cryptocurrency Commodities Alerts The indicator provides alerts for: Confirmed bullish trend changes Confirmed bearish trend changes Trend changes blocked by the chop filter The blocked-flip alert is especially useful for monitoring when the line attempts to reverse but market quality remains insufficient. Summary Median Cascade Trend is a multi-stage trend extraction system designed to reject impulsive market noise before determining direction. It first applies up to three causal median filters, progressively removing isolated spikes and short-duration disturbances. The cleaned series is then passed through a two-pole Super Smoother to extract a stable low-frequency trend line. Rather than accepting every change in slope, the indicator evaluates the quality of the movement using directional efficiency and ATR-normalized slope. Depending on the selected gate mode, trend changes can require clean directional travel, sufficient volatility-adjusted displacement, or both. This produces a persistent trend state that changes only when the filtered line turns and the surrounding movement is strong enough to justify the reversal. The final result is a robust trend-following framework that combines outlier rejection, low-pass smoothing, directional-quality measurement, and chop suppression into a single overlay. Chỉ báocủa BackQuant228