Volatility Targeting: Single Asset [BackQuant]Volatility Targeting: Single Asset
An educational example that demonstrates how volatility targeting can scale exposure up or down on one symbol, then applies a simple EMA cross for long or short direction and a higher timeframe style regime filter to gate risk. It builds a synthetic equity curve and compares it to buy and hold and a benchmark.
Important disclaimer
This script is a concept and education example only . It is not a complete trading system and it is not meant for live execution. It does not model many real world constraints, and its equity curve is only a simplified simulation. If you want to trade any idea like this, you need a proper strategy() implementation, realistic execution assumptions, and robust backtesting with out of sample validation.
Single asset vs the full portfolio concept
This indicator is the single asset, long short version of the broader volatility targeted momentum portfolio concept. The original multi asset concept and full portfolio implementation is here:
That portfolio script is about allocating across multiple assets with a portfolio view. This script is intentionally simpler and focuses on one symbol so you can clearly see how volatility targeting behaves, how the scaling interacts with trend direction, and what an equity curve comparison looks like.
What this indicator is trying to demonstrate
Volatility targeting is a risk scaling framework. The core idea is simple:
If realized volatility is low relative to a target, you can scale position size up so the strategy behaves like it has a stable risk budget.
If realized volatility is high relative to a target, you scale down to avoid getting blown around by the market.
Instead of always being 1x long or 1x short, exposure becomes dynamic. This is often used in risk parity style systems, trend following overlays, and volatility controlled products.
This script combines that risk scaling with a simple trend direction model:
Fast and slow EMA cross determines whether the strategy is long or short.
A second, longer EMA cross acts as a regime filter that decides whether the system is ACTIVE or effectively in CASH.
An equity curve is built from the scaled returns so you can visualize how the framework behaves across regimes.
How the logic works step by step
1) Returns and simple momentum
The script uses log returns for the base return stream:
ret = log(price / price )
It also computes a simple momentum value:
mom = price / price - 1
In this version, momentum is mainly informational since the directional signal is the EMA cross. The lookback input is shared with volatility estimation to keep the concept compact.
2) Realized volatility estimation
Realized volatility is estimated as the standard deviation of returns over the lookback window, then annualized:
vol = stdev(ret, lookback) * sqrt(tradingdays)
The Trading Days/Year input controls annualization:
252 is typical for traditional markets.
365 is typical for crypto since it trades daily.
3) Volatility targeting multiplier
Once realized vol is estimated, the script computes a scaling factor that tries to push realized volatility toward the target:
volMult = targetVol / vol
This is then clamped into a reasonable range:
Minimum 0.1 so exposure never goes to zero just because vol spikes.
Maximum 5.0 so exposure is not allowed to lever infinitely during ultra low volatility periods.
This clamp is one of the most important “sanity rails” in any volatility targeted system. Without it, very low volatility regimes can create unrealistic leverage.
4) Scaled return stream
The per bar return used for the equity curve is the raw return multiplied by the volatility multiplier:
sr = ret * volMult
Think of this as the return you would have earned if you scaled exposure to match the volatility budget.
5) Long short direction via EMA cross
Direction is determined by a fast and slow EMA cross on price:
If fast EMA is above slow EMA, direction is long.
If fast EMA is below slow EMA, direction is short.
This produces dir as either +1 or -1. The scaled return stream is then signed by direction:
avgRet = dir * sr
So the strategy return is volatility targeted and directionally flipped depending on trend.
6) Regime filter: ACTIVE vs CASH
A second EMA pair acts as a top level regime filter:
If fast regime EMA is above slow regime EMA, the system is ACTIVE.
If fast regime EMA is below slow regime EMA, the system is considered CASH, meaning it does not compound equity.
This is designed to reduce participation in long bear phases or low quality environments, depending on how you set the regime lengths. By default it is a classic 50 and 200 EMA cross structure.
Important detail, the script applies regime_filter when compounding equity, meaning it uses the prior bar regime state to avoid ambiguous same bar updates.
7) Equity curve construction
The script builds a synthetic equity curve starting from Initial Capital after Start Date . Each bar:
If regime was ACTIVE on the previous bar, equity compounds by (1 + netRet).
If regime was CASH, equity stays flat.
Fees are modeled very simply as a per bar penalty on returns:
netRet = avgRet - (fee_rate * avgRet)
This is not realistic execution modeling, it is just a simple turnover penalty knob to show how friction can reduce compounded performance. Real backtesting should model trade based costs, spreads, funding, and slippage.
Benchmark and buy and hold comparison
The script pulls a benchmark symbol via request.security and builds a buy and hold equity curve starting from the same date and initial capital. The buy and hold curve is based on benchmark price appreciation, not the strategy’s asset price, so you can compare:
Strategy equity on the chart symbol.
Buy and hold equity for the selected benchmark instrument.
By default the benchmark is TVC:SPX, but you can set it to anything, for crypto you might set it to BTC, or a sector index, or a dominance proxy depending on your study.
What it plots
If enabled, the indicator plots:
Strategy Equity as a line, colored by recent direction of equity change, using Positive Equity Color and Negative Equity Color .
Buy and Hold Equity for the chosen benchmark as a line.
Optional labels that tag each curve on the right side of the chart.
This makes it easy to visually see when volatility targeting and regime gating change the shape of the equity curve relative to a simple passive hold.
Metrics table explained
If Show Metrics Table is enabled, a table is built and populated with common performance statistics based on the simulated daily returns of the strategy equity curve after the start date. These include:
Net Profit (%) total return relative to initial capital.
Max DD (%) maximum drawdown computed from equity peaks, stored over time.
Win Rate percent of positive return bars.
Annual Mean Returns (% p/y) mean daily return annualized.
Annual Stdev Returns (% p/y) volatility of daily returns annualized.
Variance of annualized returns.
Sortino Ratio annualized return divided by downside deviation, using negative return stdev.
Sharpe Ratio risk adjusted return using the risk free rate input.
Omega Ratio positive return sum divided by negative return sum.
Gain to Pain total return sum divided by absolute loss sum.
CAGR (% p/y) compounded annual growth rate based on time since start date.
Portfolio Alpha (% p/y) alpha versus benchmark using beta and the benchmark mean.
Portfolio Beta covariance of strategy returns with benchmark returns divided by benchmark variance.
Skewness of Returns actually the script computes a conditional value based on the lower 5 percent tail of returns, so it behaves more like a simple CVaR style tail loss estimate than classic skewness.
Important note, these are calculated from the synthetic equity stream in an indicator context. They are useful for concept exploration, but they are not a substitute for professional backtesting where trade timing, fills, funding, and leverage constraints are accurately represented.
How to interpret the system conceptually
Vol targeting effect
When volatility rises, volMult falls, so the strategy de risks and the equity curve typically becomes smoother. When volatility compresses, volMult rises, so the system takes more exposure and tries to maintain a stable risk budget.
This is why volatility targeting is often used as a “risk equalizer”, it can reduce the “biggest drawdowns happen only because vol expanded” problem, at the cost of potentially under participating in explosive upside if volatility rises during a trend.
Long short directional effect
Because direction is an EMA cross:
In strong trends, the direction stays stable and the scaled return stream compounds in that trend direction.
In choppy ranges, the EMA cross can flip and create whipsaws, which is where fees and regime filtering matter most.
Regime filter effect
The 50 and 200 style filter tries to:
Keep the system active in sustained up regimes.
Reduce exposure during long down regimes or extended weakness.
It will always be late at turning points, by design. It is a slow filter meant to reduce deep participation, not to catch bottoms.
Common applications
This script is mainly for understanding and research, but conceptually, volatility targeting overlays are used for:
Risk budgeting normalize risk so your exposure is not accidentally huge in high vol regimes.
System comparison see how a simple trend model behaves with and without vol scaling.
Parameter exploration test how target volatility, lookback length, and regime lengths change the shape of equity and drawdowns.
Framework building as a reference blueprint before implementing a proper strategy() version with trade based execution logic.
Tuning guidance
Lookback lower values react faster to vol shifts but can create unstable scaling, higher values smooth scaling but react slower to regime changes.
Target volatility higher targets increase exposure and drawdown potential, lower targets reduce exposure and usually lower drawdowns, but can under perform in strong trends.
Signal EMAs tighter EMAs increase trade frequency, wider EMAs reduce churn but react slower.
Regime EMAs slower regime filters reduce false toggles but will miss early trend transitions.
Fees if you crank this up you will see how sensitive higher turnover parameter sets are to friction.
Final note
This is a compact educational demonstration of a volatility targeted, long short single asset framework with a regime gate and a synthetic equity curve. If you want a production ready implementation, the correct next step is to convert this concept into a strategy() script, add realistic execution and cost modeling, test across multiple timeframes and market regimes, and validate out of sample before making any decision based on the results.
Strategy!
True Three Soldiers Method (TTSM) - Breakout ConfirmationIndicator Overview
True Three Soldiers Method (TTSM) - Made in China is a quantifiable evolution beyond traditional candlestick pattern recognition. It replaces subjective visual analysis with an objective, data-driven momentum system featuring smart breakout confirmation.
Core Innovation: Beyond Traditional Pattern Recognition
Traditional three-soldier patterns merely check for three consecutive bullish/bearish candles. TTSM goes much deeper:
Dual Signal System: It identifies both single-candle and three-candle momentum signals, providing earlier warnings of potential trend changes.
Quantifiable Strength Metrics: Each signal must meet customizable thresholds for both absolute price movement (percentage change) and relative efficiency (close-to-open distance relative to total range).
Breakout Confirmation Logic: The real innovation lies in the "True Signal" mechanism. Preliminary signals are tracked, and only when price breaks above the highest high of recent bullish signals (or below the lowest low of recent bearish signals) does it trigger a confirmed entry signal. This eliminates false breakouts and ensures you're trading with confirmed momentum.
Absolute Strength: Quantifies momentum via percentage price change.
Relative Strength: Measures candlestick efficiency (close-to-open vs. total range).
True Signal Validation: A "True" entry signal triggers only after price confirms momentum by breaking above/below a cluster of recent preliminary signals, filtering out false moves.
Dual-Layer Signal System
Key Features
🔴 Amber Signals (Preparation): Single-candle or three-candle patterns that meet strength criteria. These indicate potential momentum building and can be used for preparation or light positioning.
🟢 Green Signals (True Breakout): Triggered only when price breaks above/below the recent signal cluster extremes. These represent confirmed momentum and are ideal for main entries.
🎚 Fully Customizable: Every parameter—absolute/relative strength thresholds, lookback periods, and average calculations—can be adjusted to match your trading style and market conditions.
📊 Clear Visual Feedback: Color-coded labels and reference lines make signal identification instant and intuitive.
Parameter Customization Guide
All parameters are organized in intuitive groups:
Strength Thresholds: Adjust absolute (%) and relative (%) strength requirements for both long and short signals.
First Signal Thresholds: Special thresholds for when a signal is the first in the lookback period.
Lookback & Averages: Control how many bars are considered for signal tracking and moving averages.
Strategic Application
Preparation Signals: Use amber signals to prepare for potential moves, set alerts, or enter with smaller positions.
True Signals: Green/red "True" signals indicate confirmed momentum—ideal for main entries with proper risk management.
Combination Strategy: Pair TTSM with trend indicators (like Supertrend) for higher probability trades—only take True Signals in the direction of the main trend.
POWER STRATEGY - Perfect for Meme Coins by OeZkAN📈 POWER STRATEGY - PRO EXTENDED FILTER (NO FIB ATR, TUNABLE)
This is a comprehensive, multi-layered trend-following strategy designed for Pine Script v5. It is built around a core EMA Re-Test entry logic, significantly enhanced by multiple, optional filters for Conviction, Volatility, Multi-Timeframe (MTF) Alignment, and Price Action Context (like FVAG, Divergence, Mobility, and LSOB), making it highly customizable and robust.
🌟 Core Logic & Trend Filtering
The strategy aims to trade pullbacks/re-tests toward a primary Exponential Moving Average (EMA).
Primary Trend Filter (EMA): An adjustable EMA (default 50) determines the dominant trend.
Long Condition: Price is above the EMA.
Short Condition: Price is below the EMA.
Re-Test Entry: An entry signal is generated when the price briefly touches or crosses the EMA (the "Re-Test") but immediately rejects it and closes back on the trend side (e.g., a candle's low hits the EMA, but it closes bullishly above it).
Confirmation (Optional): The useConfirmation setting enforces a waiting period (confirmationBars) after the initial re-test to ensure the price moves a minimum distance (confirmationThreshold, measured in multiples of ATR) away from the re-test low/high, confirming the bounce strength.
🎯 Advanced Filter Stack (The 'Extended Filter')
This strategy integrates multiple optional filters, providing a high degree of control over trade quality. All filters use the ATR (Average True Range) for dynamic, volatility-adjusted calculations.
Volatility Filter: Ensures the market is neither too calm (minVolatility) nor too excessively volatile (maxVolatility) by comparing the current ATR to a long-term SMA of the ATR.
Conviction Score & MTF Alignment:
Conviction Score: A weighted score (max 6 points) combining the primary EMA trend (2 points) and alignment across three user-defined Multi-Timeframes (MTF TF1, TF2, TF3, 1 point each).
MTF Agreement: Requires a minimum number of timeframes (minTFAgreement) to agree with the entry direction. The Entry Conviction Level (minConvictionEntry) then acts as the final quality gate.
FVAG Filter (Fair Value Area Gap): Uses an SMA and ATR-based bands to identify when the price is pulling back into a 'Fair Value Area' (similar to Mean Reversion context) to align entries with high-probability reversal zones.
Pro Mobility Score (Optional): Measures the size of the current bar range relative to the average bar range over a mobilityLength period. Used to ensure sufficient current market movement for an effective trade.
LSOB Filter (Last Stagnant Order Block - simplified): Tries to detect if the price is near a recent low-volatility consolidation zone, filtering for potential breakout/continuation trades from these areas.
Divergence Filter (Optional): Uses RSI to check for Bullish or Bearish Divergence, aiming to align entries with underlying momentum shifts.
🛡️ Risk Management & Controllers
Dynamic TP/SL: Take Profit (TP1, TP2, TP3) and Stop Loss (SL) levels are dynamically calculated as multiples of the current ATR value.
Minimum R:R Ratio: The strategy blocks entries where the calculated Risk-to-Reward ratio (based on SL to TP1) is below a user-defined threshold (minRiskReward).
Trailing Stop: When activated (useTrailing), the stop-loss is moved to Breakeven after TP1 is hit, with an additional buffer (beBuffer x ATR). The stop then trails the price by a defined trailingDistance x ATR.
Auto-Fix Controllers: A unique feature designed to increase stability. The controllers monitor for core anomalies (errorMonitor) and calculation issues (calcIntegrity). In auto_fix mode, they apply non-intrusive fixes (e.g., temporarily relaxing the minConvictionEntry or disabling trailing stop if errors are detected) and can block entries for severe issues (safetyBlock).
🛠️ Customization and Use
This strategy is highly tunable. Users can selectively enable/disable filters to adapt the logic to different market conditions or assets.
Grouped Inputs: Inputs are logically grouped for easy adjustment of Trend, Volatility, Confirmation, Entry, TP/SL, Trailing, and various Filter settings.
Debug Mode: Enables detailed on-chart labels for internal variables (Conviction Score, Volatility, etc.) to aid in backtesting and optimization.
📢 Check Out My Other Work!
If you find this strategy valuable, please take a moment to explore my profile on TradingView. I have developed several other unique and robust Pine Script strategies and indicators focused on combining multiple data layers (price action, volume, volatility, and order flow concepts) into high-probability trading models.
They are definitely worth a look for any serious trader!
Disclaimer
This script is for educational and testing purposes only. Trading involves significant risk, and past performance is not indicative of future results.
TDZZ ETH 15min Vault: No-Loss Martin Gale StrategyOKX:ETHUSDT.P
Strategy Overview
The ETH 15min Vault is an enhanced, high-frequency Martin Gale strategy designed specifically for Ethereum on the 15-minute chart. Its core innovation lies in integrating pre-calculated margin management with a multi-layer exit system, transforming the traditional high-risk Martingale approach into a controlled, calculated growth engine. The strategy aims for sustainable compound growth of small capitals (e.g., 1000U) in ranging markets while systematically eliminating the risk of account blow-up.
Core Concept: The "No-Loss" Guarantee
Unlike conventional Martingale systems that risk infinite losses, this strategy pre-calculates and logically reserves the total margin required for all potential layers (configurable, e.g., up to 30) at the initial entry. This ensures sufficient capital is always available for the next averaging order, preventing liquidation due to margin shortage. Combined with intelligent, proactive take-profit and safety-net closures, it creates a theoretically "No-Loss" framework for the Martin Gale method.
Key Mechanisms
1、 Smart Position Averaging:
Averaging distances expand geometrically (configurable multiplier), preventing rapid layer depletion during sharp drops.
Averaging order size increases progressively (configurable multiplier) to effectively lower the break-even point.
2、 Dynamic Multi-Stage Exit Logic:
Rebound TP: Partially closes a position when price rebounds a certain percentage from its entry, locking in profits early during oscillations.
Cycle TP: Closes the remaining position upon reaching the primary profit target, which is dynamically recalculated after each average to reflect the new aggregate cost.
Safety-Net Close (Defense Mode): Activates after a defined number of averages. Triggers a full exit if price: a) rallies significantly from the lowest point, b) retraces from a recent high, or c) fails to make a new low within a set time. This forms the final protective layer for capital preservation.
Main Advantages
✅ True Risk Isolation: Transforms Martingale's "unlimited risk" into a "defined and manageable drawdown" via pre-calculated margins and safety-net exits.
✅ Active Profit Capture: The "Rebound TP" mechanism increases win rate and capital efficiency in ranging markets.
✅ Adaptive to Volatility: Adjustable parameters for averaging distance and size allow tuning for different market conditions.
✅ High-Frequency Compounding Potential: Operates on the 15-min timeframe, offering numerous opportunities to complete profit cycles in consolidating phases.
Configuration & Parameters
Key adjustable inputs include: Initial Capital %, Averaging Distance % and Multiplier, Order Size Multiplier, Max Layers, Take-Profit %, Rebound Close %, and all Defense Mode thresholds.
This strategy significantly reduces liquidation risk through its design but does not eliminate trading risk. Substantial drawdowns can occur during strong, sustained trends. "No-Loss" refers to prevention of margin-call liquidation, not guaranteed profitability. Always conduct thorough backtesting and forward testing in a simulated environment before committing real capital. Past performance is not indicative of future results. Trade responsibly.
Momentum Quality Index Strategyfiles.fm
Welcome to the Momentum Quality Index Strategy!
This is a fairly conservative strategy with a sharp criteria for entries and taking profits. This strategy has been tested amongst the top 50 stocks with volatility over 2%, and the verdict was that the profitability was often times over 85% profitability, often times reaching over 90% profitability. This strategy thrives in more volatile environments, often times beating the buying and holding strategy YTD performance by large margins.
This strategy is highly optimized for the 30 minute chart, giving insights into shorter term movements. It is based on cash trades of $1,000 per position, with a maximum of 4 trades being placed at once.
This strategy is optimized for common stock trading in more liquid markets, and not yet optimized for options trading (however I plan on developing highly profitable strategies for this purpose soon). The take profit is customizable.
I would refer to the image link I have posted at the top of this article for the strategy's effectiveness. The strategy report on this article isn't accurate, as this strategy is based on trading $1,000 per trade, therefore over longer term periods of time will not be as successful due to the fact that there is no compounding. However, over the course of smaller time frames (such as one year), it beats buying and holding of many assets.
This strategy is meant for day trading and short term swing trading, and is not meant to beat buying and holding of successful assets over the course of long periods of time.
Vega Convexity Engine [PRO]ENGINEERED ASYMMETRY.
This is the flagship Stage 2 Specialist Model of the Vega Crypto Strategies ecosystem.
While the free "Regime Filter" tells you when to trade (filtering out chop), the Convexity Engine tells you how to trade. It activates only when the Regime Filter confirms an Impulse, classifying the specific vector of the market move to maximize risk-adjusted returns.
PRO FEATURES
This script visualizes the output of our Hierarchical Machine Learning Engine:
🚀 Directional Classification:
It does not just say "Buy." It classifies volatility into 4 distinct probability classes:
- EXPLOSION: High-confidence, high-velocity upside (Fat-Tail).
- RALLY: Standard trend continuation.
- PULLBACK: Short-term correction opportunity.
- CRASH: High-confidence downside (Long Squeeze Detection).
🛡️ Dynamic Risk Engine (Intraday Stops):
The "+" markers on your chart represent the Vega Institutional Stop Loss . These levels dynamically adjust based on Average True Range (ATR) and Volatility Z-Scores.
Strategy: If price breaches the "+" marker, the hypothesis is invalidated. Exit immediately.
📊 Institutional HUD:
A professional heads-up display showing the current Regime, Vector, and Risk Deployment status in real-time.
THE PHILOSOPHY
"Convexity" means limited downside with unlimited upside. By combining the Regime Filter (sitting in cash during noise) with Dynamic Stops (cutting losers fast), this engine is designed to capture the "fat tails" of the crypto market distribution.
🔒 HOW TO GET ACCESS
This is an Invite-Only script. It is strictly for members of Vega Crypto Strategies .
To unlock access, please visit the link in the Author Profile below or check our signature. Once subscribed via Whop, your TradingView username will be automatically authorized instantly.
Disclaimer: This tool is for educational purposes only. Past performance is not indicative of future results. Trading cryptocurrencies involves significant risk.
One Candle 5min Retest Strategy🚀 One Candle 5min Retest Strategy (OCRS) – Your Morning on Autopilot
Less drawing, more trading.
Sick of drawing the opening range manually every single morning? Or catching yourself FOMOing into trades before the candle even closes? The OCRS Indicator automates the heavy lifting for the "First Candle" / "One Candle Retest" strategy (Scarface Trades style).
It’s basically a tool to keep you honest and save you time.
🧠 Why use it?
Forced Patience: The range lines stay PURPLE while the first 5 minutes are playing out. That’s your sign to chill and wait. No early entries.
Instant Levels: Once the range closes, the lines snap to BLUE (High) and ORANGE (Low) . You see the levels immediately.
The "Zone" Finder: If price breaks out, the script finds the specific Order Block for you (the last contrary candle before the move) and draws the retest box.
Bullish Breakout? Catches the last red candle.
Bearish Breakout? Catches the last green candle.
No Confusion: Markets are messy. If price fakes a pump and then dumps, the indicator keeps the old zone and draws the new one. You see exactly what's happening.
🛠️ The Good Stuff:
Set and Forget: Auto-syncs to NY Open (09:30 EST). Works on any timeframe.
Clean Charts: Lines only run for 90 minutes. No clutter for the rest of the day.
Day Separator: A simple vertical line marks the next session. Perfect for backtesting —you know exactly when to hit pause before the next open.
No Wicks: Boxes only paint when the candle actually closes outside the range. Zero fakeouts.
Your Style: Turn boxes on/off or change colors to match your vibe.
🎯 How to trade it:
Chill for the first 5 minutes (09:30 - 09:35 NY). Purple lines = hands off.
Watch for the break.
Candle CLOSES above Blue? Wait for the Blue Box .
Candle CLOSES below Orange? Wait for the Orange Box .
The Setup: Wait for price to tap back into the box.
Entry: Find your confirmation inside that zone and take the trade.
Keep your morning simple. Install OCRS and trade with clarity.
Note: This is just a tool to help with the strategy. Risk management is still on you.
Dragon Flow Arrows (Smoothed LITE)🚀 DRAGON FLOW ARROWS — LITE | Smart Trend Engine + Clean Reversal Arrows
A lightweight but highly-optimized trend system designed for clean charts, powerful visual signals, and no-noise directional flow.
Built for traders who want simplicity, clarity, and professional-level momentum-filtered signals without over-complication.
🔥 Dragon Channel (Clean 3-Line Ribbon)
A smooth adaptive channel formed from ATR + EMA, giving you structural trend zones without clutter. No double bands, no messy overlaps just a clear upper/lower boundary.
✅ Dragon Flow Gradient
A horizontal, color-shifted flow:
🟢 Bull flow → green glow
🔴 Bear flow → red glow
Automatic blend based on trend direction
Smooth visual transitions (no vertical stripes)
✅ Momentum-Filtered Arrows (No Spam)
BUY/SELL arrows only print when:
Price breaks outside the Dragon Channel
Momentum confirms (RSI + MACD filters)
Trend flips → one clean arrow per direction
Text labels sit outside the channel for better readability.
✅ Smart Header Panel
At the top of your chart:
📌 Trend: Uptrend / Downtrend / Neutral
⚡ Impulse Strength: Weak / Normal / Strong
© FxShareRobots.com brand bar
Everything compact. Everything professional.
📊 How to Use
BUY Setup
Price moving above baseline
Dragon Flow turns bullish (cyan side)
Arrow appears below channel
SELL Setup
Price breaks below baseline
Dragon Flow turns bearish (magenta side)
Arrow pops above channel
Exit / Filter
Opposite arrow
Flow color shift
Trend panel flips
Works on Forex, Crypto, Stocks, Indices — all timeframes.
🆚 LITE vs PRO
Feature LITE PRO
Dragon Channel ✔ ✔ +Enhanced
Trend Panel ✔ ✔ +Multi-TF
Reversal Arrows ✔ ✔ + Confirmation
Momentum Filter ✔ ✔ +Expanded
Alerts ✖ ✔ +Full Suite
Reversal Zones ✖ ✔ +Predictive Map
Trade Strategy ✖ ✔ +Included + PDF
🔓 Upgrade to DRAGON FLOW — PRO
Unlock alerts, HTF confirmation, advanced momentum engine, and predictive reversal zones:
👉 fxsharerobots.com/itp/
❤️ If this helped your trading — please Like & Follow!
This supports future updates and keeps the LITE version source code free for the community.
Happy trading,
FxShareRobots Team
Market Structure Pivots with BOS & CHoCH [zazenio]What is Market Structure?
Market structure is simply the pattern of highs and lows that price creates as it moves. When you look at any chart, you'll notice price doesn't move in a straight line — it swings up, pulls back, swings up again (in an uptrend), or the opposite in a downtrend.
These swing points — the peaks and valleys — are what traders call pivots . Identifying them correctly is the foundation of understanding where a market has been and where it might go next.
What This Indicator Does
Swing Pivots automatically marks these peaks and valleys on your chart so you don't have to draw them manually. It works on any market — stocks, crypto, forex, futures, indices — and on any timeframe.
Beyond just marking pivots, this indicator also draws BOS (Break of Structure) and CHoCH (Change of Character) lines — two essential concepts that help you understand when a trend is continuing or potentially reversing.
How Pivots Are Detected
This indicator confirms pivots based on price structure, not a fixed bar count.
Here's how it works:
A swing high is confirmed when price breaks below the previous swing low. At that moment, we know the high was real — price tried to go higher, failed, and reversed. The market "proved" that level was a genuine turning point.
A swing low is confirmed when price breaks above the previous swing high. The same logic applies — price tried to go lower, failed, and reversed direction.
This creates a natural alternation: high, low, high, low. Each pivot is validated by the market's actual behavior, not by waiting for an arbitrary number of bars to pass.
Understanding BOS and CHoCH
Once you can identify pivots, the next step is understanding what happens when price breaks through them. This is where BOS and CHoCH come in.
BOS (Break of Structure)
A Break of Structure occurs when price continues in the direction of the current trend by breaking a previous pivot level.
In an uptrend : Price breaks above a previous swing high → This signals strength. Buyers are pushing price to new highs, and the trend is likely to continue.
In a downtrend : Price breaks below a previous swing low → This signals weakness. Sellers are pushing price to new lows, and the trend is likely to continue.
Think of BOS as the market saying "the trend is still intact." Each BOS confirms that the dominant side (buyers or sellers) remains in control.
CHoCH (Change of Character)
A Change of Character occurs when price breaks a pivot level in the opposite direction of the current trend. This is an early warning signal that the trend may be reversing.
In an uptrend : Price breaks below a previous swing low → This is unexpected. In a healthy uptrend, lows should hold. When they don't, it suggests buyers are losing control and sellers may be taking over.
In a downtrend : Price breaks above a previous swing high → This is unexpected. In a healthy downtrend, highs should hold. When they don't, it suggests sellers are losing control and buyers may be stepping in.
Think of CHoCH as the market's behavior "changing character" — it's no longer acting the way it should if the trend were healthy.
Why BOS and CHoCH Matter
These concepts give you a framework for reading what the market is actually doing:
BOS tells you the trend is continuing — stay with it or look for entries in that direction
CHoCH warns you the trend may be ending — time to be cautious, take profits, or look for trades in the new direction
By visualizing these breaks directly on your chart, you don't have to guess. You can see at a glance whether the market is trending smoothly (consecutive BOS) or showing signs of reversal (CHoCH).
Why This Approach Works
Most pivot indicators use a "lookback" method — they wait for a certain number of bars (say, 5 or 10) on each side of a candle before confirming it as a pivot. This creates a fixed delay. By the time the pivot appears on your chart, price has already moved on.
This indicator doesn't wait. It confirms pivots the moment price structure proves them. The result is pivots that align with how traders actually read charts — based on breaks of structure, not arbitrary countdowns.
Settings
Configuration
Swing Width : Controls how sensitive the detection is. Higher numbers show only major swings; lower numbers capture smaller moves within the structure.
Pivot Settings
High/Low Color : Customize the colors of swing high and swing low markers
Style : Choose between Triangle or Circle markers
Size : Adjust the size of pivot markers (Auto, Tiny, Small, Normal)
Structure Lines
Show CHoCH : Toggle Change of Character lines on/off
CHoCH Color : Customize the color of CHoCH lines
CHoCH Label : Show/hide the "CHoCH" text label
Show BOS : Toggle Break of Structure lines on/off
BOS Color : Customize the color of BOS lines
BOS Label : Show/hide the "BOS" text label
Use Cases
See the "skeleton" of price action at a glance
Identify potential support and resistance levels
Understand if the market is trending or ranging
Spot trend continuations with BOS lines
Catch early reversal signals with CHoCH lines
Build a foundation for more advanced trading strategies
━━━━━━━━━━━━━━━━━━━━━━
Version History
v1.1
Added BOS (Break of Structure) lines to visualize trend continuation
Added CHoCH (Change of Character) lines to identify potential trend reversals
Added toggle options for BOS and CHoCH visibility
Added customizable colors for structure lines
Added optional labels for BOS and CHoCH
v1.0
Initial release
Automatic swing high and swing low detection
Structure-based pivot confirmation (not fixed lookback)
Customizable pivot markers (style, size, colors)
Adjustable swing width sensitivity
━━━━━━━━━━━━━━━━━━━━━━
Disclaimer:
This script is provided for educational and informational purposes only. It is not financial advice and does not constitute a recommendation to buy or sell any financial instrument. Always do your own research and trade at your own risk.
BTC DCA Risk Metric StrategyBTC DCA Risk Strategy - Automated Dollar Cost Averaging with 3Commas Integration
Overview
This strategy combines the proven Oakley Wood Risk Metric with an intelligent tiered Dollar Cost Averaging (DCA) system, designed to help traders systematically accumulate Bitcoin during periods of low risk and take profits during high-risk conditions.
Key Features
📊 Multi-Component Risk Assessment
4-Year SMA Deviation: Measures Bitcoin's distance from its long-term mean
20-Week MA Analysis: Tracks medium-term momentum shifts
50-Day/50-Week MA Ratio: Captures short-to-medium term trend strength
All metrics are normalized by time to account for Bitcoin's maturing market dynamics
💰 3-Tier DCA Buy System
Level 1 (Low Risk): Conservative entry with base allocation
Level 2 (Lower Risk): Increased allocation as opportunity improves
Level 3 (Extreme Low Risk): Maximum allocation during rare buying opportunities
Buys execute every bar while risk remains below thresholds, enabling true DCA accumulation
📈 Progressive Profit Taking
Sell Level 1: Take initial profits as risk increases
Sell Level 2: Scale out further positions during elevated risk
Sell Level 3: Final exit during extreme market conditions
Sell levels automatically reset when new buy signals occur, allowing flexible re-entry
🤖 3Commas Integration
Fully automated webhook alerts for Custom Signal Bots
JSON payloads formatted per 3Commas API specifications
Supports multiple exchanges (Binance, Coinbase, Kraken, Gemini, Bybit)
Configurable quote currency (USD, USDT, BUSD)
How It Works
The strategy calculates a composite risk metric (0-1 scale):
0.0-0.2: Extreme buying opportunity (green zone)
0.2-0.5: Favorable accumulation range (yellow zone)
0.5-0.8: Neutral to cautious territory (orange zone)
0.8-1.0+: High risk, profit-taking zone (red zone)
Buy Logic: As risk decreases, position sizes increase automatically. If risk drops from L1 to L3 threshold, the strategy combines all three tier allocations for maximum exposure.
Sell Logic: Sequential profit-taking ensures you capture gains progressively. The system won't advance to Sell L2 until L1 completes, preventing premature full exits.
Configuration
Risk Metric Parameters:
All calculations use Bitcoin price data (any BTC chart works)
Time-normalized formulas adapt to market maturity
No manual parameter tuning required
Buy Settings:
Set risk thresholds for each tier (default: 0.20, 0.10, 0.00)
Define dollar amounts per tier (default: $10, $15, $20)
Fully customizable to your risk tolerance and capital
Sell Settings:
Configure risk thresholds for profit-taking (default: 1.00, 1.50, 2.00)
Set percentage of position to sell at each level (default: 25%, 35%, 40%)
3Commas Setup:
Create a Custom Signal Bot in 3Commas
Copy Bot UUID and Secret Token into strategy inputs
Enable 3Commas Alerts checkbox
Create TradingView alert: Condition → "alert() function calls only", Webhook → api.3commas.io
Backtesting Results
Strengths:
Systematically buys dips without emotion
Averages down during extended bear markets
Captures explosive bull run profits through tiered exits
Pyramiding (1000 max orders) allows true DCA behavior
Considerations:
Requires sufficient capital for multiple buys during prolonged downtrends
Backtest on Daily timeframe for most reliable signals
Past performance does not guarantee future results
Visual Design
The indicator pane displays:
Color-coded risk metric line: Changes from white→red→orange→yellow→green as risk decreases
Background zones: Green (buy), yellow (hold), red (sell) areas
Dashed threshold lines: Clear visual markers for each buy/sell level
Entry/Exit labels: Green buy labels and orange/red sell labels mark all trades
Credits
Original Risk Metric: Oakley Wood
Strategy Development & 3Commas Integration: Claude AI (Anthropic)
Modifications: pommesUNDwurst
Disclaimer
This strategy is for educational and informational purposes only. Cryptocurrency trading carries substantial risk of loss. Always conduct your own research and never invest more than you can afford to lose. The authors are not financial advisors and assume no responsibility for trading decisions made using this tool.
Hash Ratings EngineHash Ratings Engine - Technical Consensus Strategy
A systematic trading strategy that harnesses TradingView's Technical Ratings to generate high-conviction entries with institutional-grade risk management.
What It Does
This strategy aggregates the consensus of 26+ technical indicators (RSI, MACD, Stochastics, multiple Moving Averages, etc.) into a single actionable signal. When enough indicators align bullish or bearish, the engine triggers an entry. Built-in trend filtering and ATR-based exits keep you on the right side of the market.
Key Features
Trend Filter - Only takes longs in uptrends, shorts in downtrends. This single filter typically improves results by 20-40% by avoiding counter-trend trades.
ATR-Based Risk Management - Stop loss and trailing stops adapt to current market volatility. Tight stops in calm markets, wider stops in volatile conditions.
Cooldown System - After a losing trade, the strategy waits before re-entering. This prevents the consecutive loss streaks that destroy accounts.
Clean Visuals - Fluorescent entry/exit signals with price level references. See exactly where you got in and out.
Settings Guide
Indicator Timeframe: Leave blank for current chart. Use higher timeframe for fewer, higher-quality signals.
Rating Source: "All" for balanced approach. "MAs" for trend-following. "Oscillators" for mean-reversion.
Entry Thresholds
Strong Signal Threshold: Higher = fewer trades but better conviction. Start at 0.5, test 0.4-0.6.
Risk Management
ATR Period: 12 is responsive, 14 is standard, 20+ is smoother.
Stop Loss: 2-3x ATR for tight stops, 3.5-4x for moderate, 5x+ for wide.
Trail Activation: How far price must move in profit before trailing begins.
Trail Offset: How closely the trail follows price.
Trend Filter
EMA Length: 150 works well on 4H charts. Use 100 for lower timeframes, 200 for daily.
Trade Timing
Cooldown: Keep enabled. 5 bars is a good starting point.
Best Practices
Start with default settings and backtest on your preferred instrument. Adjust the Strong Signal Threshold first - this has the biggest impact on trade frequency. Then tune the EMA length to match your timeframe. Finally, optimize the ATR multipliers for your risk tolerance.
Works on any liquid market - crypto, forex, stocks, futures. Higher timeframes (4H, Daily) tend to produce cleaner signals than lower timeframes.
Disclaimer
Past performance does not guarantee future results. Always backtest thoroughly and use proper position sizing. This strategy is for educational purposes - trade at your own risk.
MA and EMA Cross [Pure Strategy]Simple EMA/SMA Crossover
This indicator signals BUY or SELL entries when the Fast EMA crosses the Slow SMA.
✅ Best For: Catching the start of strong trends.
⚠️ Warning: May give false signals in sideways (choppy) markets.
💡 Tip: Use this as a secondary confirmation for your existing strategy, rather than a standalone tool.
Alphabet Long Trigger (Björn)Alphabet Trigger Dezember 2025:
Kurs 267–269 €
grüne Kerze mit höherem Tief
Volumen-Lebenszeichen
Nasdaq nicht im Abwärtsmodus
Alphabet Momentum Pullback Strategy — Brief Description
This strategy targets high-quality pullbacks within a confirmed uptrend and enters a long position only when price, structure, volume, and market context align.
A trade is triggered when:
Price enters the buy zone between €267–€269, signaling a controlled pullback.
The chart forms the first green candle with a higher low, indicating buyers are returning.
Volume shows a positive uptick (at least above the recent average), confirming real demand.
The Nasdaq is not falling, ensuring the broader tech market is stable and not in risk-off mode.
The strategy avoids entries triggered solely by price and waits for multi-factor confirmation, reducing false breakouts and momentum traps. It is designed for disciplined swing traders who prioritize trend alignment, volume confirmation, and market context before entering a position.
US Market Long Horizon Momentum Summary in one paragraph
US Market Long Horizon Momentum is a trend following strategy for US index ETFs and futures built around a single eighteen month time series momentum measure. It helps you stay long during persistent bull regimes and step aside or flip short when long term momentum turns negative.
Scope and intent
• Markets. Large cap US equity indices, liquid US index ETFs, index futures
• Timeframes. 4h/ Daily charts
• Default demo used in the publication. SPY on 4h timeframe chart
• Purpose. Provide a minimal long bias index timing model that can reduce deep drawdowns and capture major cycles without parameter mining
• Limits. This is a strategy. Orders are simulated on standard candles only
Originality and usefulness
• Unique concept or fusion. One unscaled multiple month log return of an external benchmark symbol drives all entries and exits, with optional volatility targeting as a single risk control switch.
• Failure mode addressed. Fully passive buy and hold ignores the sign of long horizon momentum and can sit through multi year drawdowns. This script offers a way to step down risk in prolonged negative momentum without chasing short term noise.
• Testability. All parameters are visible in Inputs and the momentum series is plotted so users can verify every regime change in the Tester and on price history.
• Portable yardstick. The log return over a fixed window is a unit that can be applied to any liquid symbol with daily data.
Method overview in plain language
The method looks at how far the benchmark symbol has moved in log return terms over an eighteen month window in our example. If that long horizon return is positive the strategy allows a long stance on the traded symbol. If it is negative and shorts are enabled the strategy can flip short, otherwise it goes flat. There is an optional realised volatility estimate on the traded symbol that can scale position size toward a target annual volatility, but in the default configuration the model uses unit leverage and only the sign of momentum matters.
Base measures
Return basis. The core yardstick is the natural log of close divided by the close eighteen months ago on the benchmark symbol. Daily log returns of the traded symbol feed the realised volatility estimate when volatility targeting is enabled.
Components
• Component one Momentum eighteen months. Log of benchmark close divided by its close mom_lookback bars ago. Its sign defines the trend regime. No extra smoothing is applied beyond the long window itself.
• Component two Realised volatility optional. Standard deviation of daily log returns on the traded symbol over sixty three days. Annualised by the square root of 252. Used only when volatility targeting is enabled.
• Optional component Volatility targeting. Converts target annual volatility and realised volatility into a leverage factor clipped by a maximum leverage setting.
Fusion rule
The model uses a simple gate. First compute the sign of eighteen month log momentum on the benchmark symbol. Optionally compute leverage from volatility. The sign decides whether the strategy wants to be long, short, or flat. Leverage only rescales position size when enabled and does not change direction.
Signal rule
• Long suggestion. When eighteen month log momentum on the benchmark symbol is greater than zero, the strategy wants to be long.
• Short suggestion. When that log momentum is less than zero and shorts are allowed, the strategy wants to be short. If shorts are disabled it stays flat instead.
• Wait state. When the log momentum is exactly zero or history is not long enough the strategy stays flat.
• In position. In practice the strategy sits IN LONG while the sign stays positive and flips to IN SHORT or flat only when the sign changes.
Inputs with guidance
Setup
• Momentum Lookback (months). Controls the horizon of the log return on the benchmark symbol. Typical range 6 to 24 months. Raising it makes the model slower and more selective. Lowering it makes it more reactive and sensitive to medium term noise.
• Symbol. External symbol used for the momentum calculation, SPY by default. Changing it lets you time other indices or run signals from a benchmark while trading a correlated instrument.
Logic
• Allow Shorts. When true the strategy will open short positions during negative momentum regimes. When false it will stay flat whenever momentum is negative. Practical setting is tied to whether you use a margin account or an ETF that supports shorting.
Internal risk parameters (not exposed as inputs in this version) are:
• Target Vol (annual). Target annual volatility for volatility targeting, default 0.2.
• Vol Lookback (days). Window for realised volatility, default 63 trading days.
• Max Leverage. Cap on leverage when volatility targeting is enabled, default 2.
Usage recipes
Swing continuation
• Signal timeframe. Use the daily chart.
• Benchmark symbol. Leave at SPY for US equity index exposure.
• Momentum lookback. Eighteen months as a default, with twelve months as an alternative preset for a faster swing bias.
Properties visible in this publication
• Initial capital. 100000
• Base currency. USD
• Default order size method. 5% of the total capital in this example
• Pyramiding. 0
• Commission. 0.03 percent
• Slippage. 3 ticks
• Process orders on close. On
• Bar magnifier. Off
• Recalculate after order is filled. Off
• Calc on every tick. Off
• All request.security calls use lookahead = barmerge.lookahead_off
Realism and responsible publication
The strategy is for education and research only. It does not claim any guaranteed edge or future performance. All results in Strategy Tester are hypothetical and depend on the data vendor, costs, and slippage assumptions. Intrabar motion is not modeled inside daily bars so extreme moves and gaps can lead to fills that differ from live trading. The logic is built for standard candles and should not be used on synthetic chart types for execution decisions.
Performance is sensitive to regime structure in the US equity market, which may change over time. The strategy does not protect against single day crash risk inside bars and does not model gap risk explicitly. Past behavior of SPY and the momentum effect does not guarantee future persistence.
Honest limitations and failure modes
• Long sideways regimes with small net change over eighteen months can lead to whipsaw around the zero line.
• Very sharp V shaped reversals after deep declines will often be missed because the model waits for momentum to turn positive again.
• The sample size in a full SPY history is small because regime changes are infrequent, so any test must be interpreted as indicative rather than statistically precise.
• The model is highly dependent on the chosen lookback. Users should test nearby values and validate that behavior is qualitatively stable.
Legal
Education and research only. Not investment advice. You are responsible for your own decisions. Always test on historical data and in simulation with realistic costs before any live use.
AlphaNatt | FINAL REVELATION [Visual God]AlphaNatt | The Final Revelation
"Where Information Theory meets Market Geometery."
The AlphaNatt is a comprehensive market structure and volumetric analysis suite designed for the institutional-grade trader. It merges advanced quantitative concepts—specifically Shannon Entropy and Neural Pattern Filtering—with a "Holographic" visual interface that prioritizes clarity over clutter.
This is not just an indicator; it is a complete decision-support system that answers three critical questions:
Is the market chaotic or ordered? (Entropy Engine)
Where is the liquidity? (Volumetric Heatmap)
What is the true structure? (Fractal Geometry)
🌌 The Gen 100 Math Engine
At the core of this script lies a unique implementation of Information Theory.
1. Shannon Entropy (The Chaos Filter)
Most indicators fail because they try to predict "Noise". This script calculates the Entropy (in Bits) of the recent price action.
High Entropy: The market is in a "Random Walk" state. Visuals fade out, transparency increases, and signals are suppressed.
Low Entropy: The market is "Ordered" and approaching a singularity/decision point. Visuals glow brightly to indicate a high-probability environment.
2. Neural Pattern Recognition
The diamond signals (Cyan/Magenta) are not simple simple crossovers. They are driven by a composite logic simulating a neural filter:
Inputs: Normalised RSI + Momentum Divergence + Volatility State.
Logic: Signals only trigger when the market is statistically overextended AND showing signs of momentum decay.
💎 Holographic Features
🔥 Volumetric Heatmap
The script scans historical price action to build a Volume Profile Heatmap on the right side of the chart.
Purple/Blue Zones: These represent High Volume Nodes (HVNs). These act as "Gravity Wells" for price—often stopping trends or acting as launchpads for reversals.
POC (Point of Control): The bright green line indicates the price level with the absolute highest volume in the lookback period.
🌀 Fractal Structure Lines
Price action is often noisy. The script uses a Fractal Pivot Algorithm (Length 5) to identify the "True Highs" and "True Lows".
It connects these points with dashed "Neural Lines" to show the naked market skeleton.
This instantly reveals if you are in a trend of Higher Highs or a breakdown of Lower Lows.
🖥️ The Heads-Up Display (HUD)
A minimalist dashboard keeps you informed of the math underneath:
ENTROPY: The raw bit-score of market chaos.
REGIME: Tells you instantly if you are in "ORDER" (Tradeable) or "CHAOS" (Sit out).
STRUCT: Real-time status of the fractal structure (Breakout/Breakdown/Ranging).
⚙️ Settings & Configuration
Theme: Choose between "Cyber" (Neon), "Aeon" (Deep Blue), or "Gold" (Luxury).
Max Entropy: Adjust the sensitivity of the Chaos Filter. Lower values = stricter filtering (fewer trades).
Heatmap Depth: Control how far back the volume profile scans.
⚠️ Disclaimer
This tool is designed for educational market analysis. "Entropy" and "Neural" refer to the mathematical algorithms used to process price data and do not guarantee future performance. Always manage risk responsible.
Quantellics: NQ Reverse From EMA [Strategy]//@version=5
// © 2025 Quantellics. All rights reserved.
strategy("Quantellics: NQ Reverse From EMA ", overlay = true, default_qty_type = strategy.percent_of_equity, default_qty_value = 100, pyramiding = 0)
// Inputs
emaLen = input.int(60, "EMA Length", minval = 1)
rsiLen = input.int(14, "RSI Length", minval = 1)
lb = input.int(10, "Lookback Candles", minval = 1)
entryOff = input.float(75.0, "Entry Offset ($)", minval = 0, step = 1)
slDollar = input.float(50.0, "Stop Loss ($)", minval = 0, step = 1)
tpDollar = input.float(50.0, "Take Profit ($)", minval = 0, step = 1)
trailAct = input.float(30.0, "Trail Activation ($)", minval = 0, step = 1)
trailOff = input.float(30.0, "Trail Offset ($)", minval = 0, step = 1)
trailDelay = input.int(2, "Trail Delay (Candles)", minval = 0, step = 1)
ssH = input.int(9, "Session Start Hour (ET)", minval = 0, maxval = 23)
ssM = input.int(30, "Session Start Minute (ET)", minval = 0, maxval = 59)
seH = input.int(12, "Session End Hour (ET)", minval = 0, maxval = 23)
seM = input.int(0, "Session End Minute (ET)", minval = 0, maxval = 59)
// Session calc
int h = hour(time, "America/New_York")
int m = minute(time, "America/New_York")
sStart = ssH * 60 + ssM
sEnd = seH * 60 + seM
nowMin = h * 60 + m
inSess = nowMin >= sStart and nowMin < sEnd
eos = nowMin >= sEnd
// Indicators
ema60 = ta.ema(close, emaLen)
rsi = ta.rsi(close, rsiLen)
hiN = ta.highest(high, lb)
loN = ta.lowest(low, lb)
// Levels
longLvl = hiN - entryOff
shortLvl = loN + entryOff
// Conditions
longOk = high > ema60 and rsi > 50 and strategy.position_size == 0 and inSess and not eos
shortOk = low < ema60 and rsi < 50 and strategy.position_size == 0 and inSess and not eos
// State
var float ePrice = na
var float slLvl = na
var float tpLvl = na
var int bars = 0
if strategy.position_size != 0
bars += 1
else
bars := 0
// Orders
if longOk
strategy.entry("Long", strategy.long, limit = longLvl)
else
strategy.cancel("Long")
if shortOk
strategy.entry("Short", strategy.short, limit = shortLvl)
else
strategy.cancel("Short")
if strategy.position_size > 0
if bars > trailDelay
strategy.exit("Long Exit", "Long", stop = strategy.position_avg_price - slDollar, limit = strategy.position_avg_price + tpDollar, trail_points = trailAct, trail_offset = trailOff)
else
strategy.exit("Long Exit", "Long", stop = strategy.position_avg_price - slDollar, limit = strategy.position_avg_price + tpDollar)
if strategy.position_size < 0
if bars > trailDelay
strategy.exit("Short Exit", "Short", stop = strategy.position_avg_price + slDollar, limit = strategy.position_avg_price - tpDollar, trail_points = trailAct, trail_offset = trailOff)
else
strategy.exit("Short Exit", "Short", stop = strategy.position_avg_price + slDollar, limit = strategy.position_avg_price - tpDollar)
// EOS flat
if eos and strategy.position_size != 0
strategy.close_all(comment = "EOS Exit")
if eos
strategy.cancel_all()
// Tracking
if strategy.position_size > 0 and strategy.position_size <= 0
ePrice := strategy.position_avg_price
slLvl := ePrice - slDollar
tpLvl := ePrice + tpDollar
if strategy.position_size < 0 and strategy.position_size >= 0
ePrice := strategy.position_avg_price
slLvl := ePrice + slDollar
tpLvl := ePrice - tpDollar
// Plots
plot(ema60, color = color.blue, title = "EMA 60", linewidth = 2)
plot(hiN, color = color.new(color.green, 50), title = "Lookback High", linewidth = 1, style = plot.style_stepline)
plot(loN, color = color.new(color.red, 50), title = "Lookback Low", linewidth = 1, style = plot.style_stepline)
plot(longLvl, color = color.new(color.orange, 30), title = "Long Entry", linewidth = 2)
plot(shortLvl, color = color.new(color.purple, 30), title = "Short Entry", linewidth = 2)
Momentum Factor Model [QuantAlgo]🟢 Overview
The Momentum Factor Model is a multi-horizon momentum analysis system that combines weighted return calculations with risk-adjusted price projections to identify and track persistent directional trends. The indicator employs a quantitative approach by measuring momentum across multiple timeframes simultaneously, applying exponential decay weighting to balance recent versus historical price action, and constructing volatility-normalized boundaries for trend validation. This factor-based methodology provides traders and investors with a systematic framework for momentum regime identification, trend persistence evaluation, and dynamic support/resistance determination across diverse market conditions and timeframes.
🟢 How It Works
The indicator constructs a composite momentum factor by calculating percentage returns over three distinct lookback periods (1, 3, and 5 bars) and combining them using exponentially decayed weights. The momentum decay parameter controls the relative importance of each timeframe, with higher decay values creating more balanced weighting between recent and historical momentum, while lower values emphasize immediate price action. This weighted momentum factor captures the multi-dimensional nature of trend strength rather than relying on a single timeframe measurement.
The expected return is derived by smoothing the momentum factor over a user-defined period, establishing a baseline for anticipated price movement based on recent momentum characteristics. This expected return then projects a factor-based price estimate, which undergoes risk adjustment through volatility normalization, creating a price estimate that accounts for both directional bias and market volatility conditions.
🟢 How to Use It
▶ Enter Long positions when the momentum factor dots (⏺) transition from red to green (bullish) , indicating the momentum factor model has confirmed positive directional bias. The color change represents a validated shift where the factor line has broken through the lower boundary and begun tracking the upper bound, signaling momentum reversal to the upside. Conversely, enter Short positions or exit existing Longs when the dots shift from green to red (bearish) , confirming negative momentum establishment and downward trend tracking.
The momentum factor dots function as a dynamic momentum-based reference pathway that can be used for position management and risk control. During bullish phases, the dot formation represents a momentum-weighted support zone where pullbacks may find stability before continuation. During bearish trends, it acts as resistance where rallies may encounter selling pressure. Price action relative to the momentum factor pathway provides context on trend health: sustained price movement in the direction of the trend (above the dots during bullish phases, below during bearish phases) confirms momentum persistence, while repeated violations may suggest weakening directional conviction.
▶ Configure alert notifications to monitor trend changes without continuous chart observation. The indicator provides three alert types: "Bullish Momentum Signal" triggers specifically on upward trend reversals, "Bearish Momentum Signal" captures downward momentum shifts, and "Momentum Trend Change" fires on any directional transition. These alerts activate only when the trend state changes from one regime to another, eliminating false triggers from intrabar noise or temporary boundary touches that don't result in confirmed trend reversals.
▶ The indicator also offers six pre-designed color schemes (Classic, Aqua, Cosmic, Ember, Neon, Custom) optimized for various chart backgrounds and visual preferences, ensuring the momentum trend remains clearly visible under different display conditions. The bar coloring feature overlays trend direction directly onto the price candles, providing immediate visual confirmation of the momentum regime without needing to reference the dot pattern position.
🟢 Pro Tips for Trading and Investing
▶ Align the configuration preset with your trading timeframe and objectives: Fast Response settings excel on 1-15 minute charts for scalping and day trading where capturing quick momentum shifts is paramount, though this comes with increased signal frequency and potential whipsaws in ranging conditions. Default parameters suit hourly to daily charts for swing trading, providing balanced responsiveness without excessive noise. Smooth Trend configuration works best on 4-hour to weekly timeframes for position trading and investment analysis, prioritizing trend stability over timing precision and significantly reducing false reversals during consolidation periods.
▶ Context matters significantly for momentum-based systems. The indicator performs optimally during trending market regimes where directional persistence exists and may struggle during sideways consolidation where momentum lacks consistency. Before taking signals, assess the broader market structure: look for established higher highs/higher lows (uptrend) or lower highs/lower lows (downtrend) on higher timeframes to confirm you're trading with the dominant directional bias. During range-bound periods, reduce position sizing or wait for the momentum factor dots to establish a clear directional slope and consistent movement before committing capital.
▶ Layer the momentum factor model with complementary analysis rather than using it in isolation. Combine trend signals with volume confirmation (increasing volume on trend changes suggests institutional participation), key support/resistance levels (signals near major levels carry higher probability), and volatility context (ATR expansion can precede significant moves). Consider the momentum decay parameter's impact: values near 0.85 make the model highly sensitive to recent price action, ideal for fast-moving markets but prone to false signals; values near 0.95 create smoother momentum estimates that better filter noise but may lag major reversals.
▶ Implement dynamic position management using the momentum factor pathway as a trailing reference framework. Rather than placing fixed stops, observe the dot formation's progression: as long as it maintains its directional slope and price respects it as support (bullish) or resistance (bearish), the momentum regime remains intact. Exit or tighten stops when price closes decisively through the momentum factor dots against your position, or when the dot pathway itself flattens (losing slope) indicating momentum exhaustion. For portfolio allocation, scale position sizes based on momentum factor strength, e.g., steeper dot progression angles and faster advancement suggest stronger momentum worthy of larger allocations within your risk parameters.
Trend Signal MomentumOVERVIEW
Signal Trend Momentum is a hybrid strategy that combines multiple confirmations and filters to obtain better potential trading signals. Each confirmation and filter in Signal Trend Momentum aims to avoid possible false and trap signals.
HYBRID CONCEPTS
Smart Money Concept – This indicator forms market structure and Bullish & Bearish Order Block areas to make it easier to identify market trends and strong areas where price reversals often occur. Its purpose is to simplify recognizing market direction and serve as the first confirmation.
MSS + BOS (Market Structure Shift + Break of Structure) – This indicator serves as additional confirmation for the Smart Money Concept. With the presence of two types of market structure, the market trend direction becomes clearer and more convincing.
RSI Momentum Signal – This indicator becomes the third confirmation. When the Market Trend is clear and convincing, supported by the formation of Bearish and Bullish Order Blocks, the role of the Momentum Signal here becomes crucial as it provides trend momentum based on overbought and oversold areas.
Momentum Position – This indicator becomes the next confirmation based on buyer and seller VOLUME in the market. If buyer volume is higher, the momentum position will be depicted on the chart with an upward arrow, and conversely, if seller volume is higher, it will be depicted with a downward arrow.
SnR (Support and Resistance) – This final indicator is Support and Resistance, which will serve as the last and more convincing confirmation. Support and Resistance will strengthen the Order Block areas formed by the Smart Money Concept indicator. A Bullish Order Block + Support creates a higher possibility for an upward trend in the market, conversely, a Bearish Order Block + Resistance creates a higher possibility for a downward trend in the market.
The combination of these several indicators will provide a strong market direction + persistent buyer and seller areas, as well as depict momentum based on volume + RSI which serve as additional confirmations.
These additional confirmations will produce stronger signals and help avoid false and trap signals in the market.
HOW TO USE
A SHORT SIGNAL will be strong if there is a Downtrend Market Structure + Bearish Order Block + Resistance + Oversold RSI Momentum + Strong Seller Volume Momentum.
A LONG SIGNAL will be strong if there is an Uptrend Market Structure + Bullish Order Block + Support + Overbought RSI Momentum + Strong Buyer Volume Momentum.
CONCLUSION
Signal Trend Momentum is a combination of several powerful indicators designed to produce stronger, clearer, and easier-to-read signals.
This strategy is highly suitable for traders seeking more convincing trade signals based on multiple confirmations from the combined indicators, thereby creating a strong signal with a higher probability.
Angular Resistance & Breakout/BreakdownAngular Resistance & Breakout/Breakdown (Dynamic Trendlines)
This indicator provides a dynamic approach to identifying major support and resistance levels by fitting Linear Regression lines to recent pivot points (swing highs and swing lows). Unlike static horizontal lines, these "Angular" trendlines adapt to the market's slope, providing continuously adjusting targets for resistance and support, along with signals for confirmed breakouts and breakdowns.
💡 Key Features
Dynamic Trendlines: Utilizes Linear Regression to automatically draw sloped trendlines based on a configurable number of the most recent swing pivots.
Confirmed Signals: Generates clear Breakout (▲) and Breakdown (▼) signals with optional buffer and sensitivity filters to reduce noise.
Customizable Inputs: Fine-tune the pivot detection period, the number of points used for regression, line extension, and signal sensitivity.
On-Chart Info Panel: A table displays real-time data, including the number of detected pivot points and the current calculated price level of the dynamic lines.
⚙️ How It Works (The Logic)
Pivot Detection: The script uses the standard ta.pivothigh() and ta.pivotlow() functions to reliably identify swing points, based on the Pivot Left and Pivot Right settings. These points are stored in dynamic arrays (highs for resistance, lows for support).
Angular Line Generation: A custom function, f_regression_from_array, performs a Linear Regression analysis using the bar index (X-axis) and the pivot price (Y-axis) for the Points to use. This calculation determines the optimal slope and intercept to draw a best-fit dynamic line through the identified pivot points.
Breakout/Breakdown Confirmation:
Breakout: Triggered when the current close price crosses above the dynamic resistance line plus the user-defined Breakout buffer.
Breakdown: Triggered when the current close price crosses below the dynamic support line minus the user-defined Breakout buffer.
Sensitivity Filter: An optional filter requires the price movement on the signal bar to exceed a minimum percentage (Label sensitivity) away from the line to confirm the momentum of the move.
Strategy: HMA 50 + Supertrend SniperHMA 50 + Supertrend Confluence Strategy (Trend Following with Noise Filtering)
Description:
Introduction and Concept This strategy is designed to solve a common problem in trend-following trading: Lag vs. False Signals. Standard Moving Averages often lag too much, while price action indicators can generate false signals during choppy markets. This script combines the speed of the Hull Moving Average (HMA) with the volatility-based filtering of the Supertrend indicator to create a robust "Confluence System."
The primary goal of this script is not just to overlay two indicators, but to enforce a strict rule where a trade is only taken when Momentum (HMA) and Volatility Direction (Supertrend) are in perfect agreement.
Why this combination? (The Logic Behind the Mashup)
Hull Moving Average (HMA 50): We use the HMA because it significantly reduces lag compared to SMA or EMA by using weighted calculations. It acts as our primary Trend Direction detector. However, HMA can be too sensitive and "whipsaw" during sideways markets.
Supertrend (ATR-based): We use the Supertrend (Factor 3.0, Period 10) as our Volatility Filter. It uses Average True Range (ATR) to determine the significant trend boundary.
How it Works (Methodology) The strategy uses a boolean logic system to filter out low-quality trades:
Bullish Confluence: The HMA must be rising (Slope > 0) AND the Close Price must be above the Supertrend line (Uptrend).
Bearish Confluence: The HMA must be falling (Slope < 0) AND the Close Price must be below the Supertrend line (Downtrend).
The "Choppy Zone" (Noise Filter): This is a unique feature of this script. If the HMA indicates one direction (e.g., Rising) but the Supertrend indicates the opposite (e.g., Downtrend), the market is considered "Choppy" or indecisive. In this state, the script paints the candles or HMA line Gray and exits all positions (optional setting) to preserve capital.
Visual Guide & Signals To make the script easy to interpret for traders who do not read Pine Script, I have implemented specific visual cues:
Green Cross (+): Indicates a LONG entry signal. Both HMA and Supertrend align bullishly.
Red Cross (X): Indicates a SHORT entry signal. Both HMA and Supertrend align bearishly.
Thick Line (HMA): The main line changes color based on the trend.
Green: Bullish Confluence.
Red: Bearish Confluence.
Gray: Divergence/Choppy (No Trade Zone).
Thin Step Line: This is the Supertrend line, serving as your dynamic Trailing Stop Loss.
Strategy Settings
HMA Length: Default is 50 (Mid-term trend).
ATR Factor/Period: Default is 3.0/10 (Standard for trend catching).
Exit on Choppy: A toggle switch allowing users to decide whether to hold through noise or exit immediately when indicators disagree.
Risk Warning This strategy performs best in trending markets (Forex, Crypto, Indices). Like all trend-following systems, it may experience drawdown during prolonged accumulation/distribution phases. Please backtest with your specific asset before using it with real capital.
OBV + WaveTrend Volume Scalper [GratefulFutures]This script is a combination script of three different strategies that provides buy and sell signals based on the change of volume with momentum confirmations.
Sources used:
This script relies on the outstanding scripts of the great script writer LazyBear: LazyBear
The following scripts were used in this publication:
1. A modified "On-Balance Volume Oscillator" modified from LazyBear's original script:
2. Wavetrend Oscillator with crosses, Author: LazyBear
3. Squeeze Momentum Oscillator, Author: LazyBear
This script functions based on the following criteria being true:
1. On balance volume oscillator turning from negative to positive (buy) or positive to negative (sell)
2. Squeeze Momentum value is increasing (buy) or decreasing (sell)
3. Wavetrend 1 (wt1) is greater than wavetrend 2 (wt2) (buy)/ Wavetrend 1 (wt1) is less than wavetrend 2 (wt2) (sell)
By combining these factors the indicator is able to signal exactly when net buying turns to net selling (OBV) and when this change is most advantageous to continue based on the momentum and price action of the underlying asset (SQMOMO and Wavetrend).
This allows you to pair volume and price action for a powerful tool to identify where price will reverse or continue providing exceptional entries for short term trades, especially when combined with other aspects such as support and resistance, or volume profile.
How to use:
Simply adjust the settings to your preference and read the given signals as generated.
Settings
There are multiple ways to tune the signals generated. It is set standard for my preferred use on a 1 minute chart.
OBV Oscillator Settings
The first 4 dropdowns in the Inputs section tune the On Balance Volume Oscillator (OBVO) portion of the indicator. You can choose if you want it to calculate based on close, open, high, low, or other value.
The most impactful in the entire settings is going to be the length and smoothing of the OBVO EMA. Making this number lower increasing the sensitivity to changes in volume, making the signals come quicker but is more susceptible to quick fluctuations. A value of between (5-20) is reasonable for the OBVO EMA length. There is a separate smoothing factor titled OBV Smoothing Length and below that, OBV Smoothing Type , a value of (2) is standard with "SMA" for smoothing type with a value of between 2-10 being reasonable. You may also play with these values to see what you like for your trading style.
Wavetrend Settings
The next 3 options are to modify the wavetrend portion of the indicator. I do not modify these from standard, and feel that they work appropriately on all time frames at the following values: n1 length (10), n2 length (20), Wavetrend Signal SMA length (4)
Squeeze Momentum Settings
The following 5 options through the end modify the Squeeze momentum portion of the indicator. The only one that modifies the signals generated is the KC Length , Making this number lower increasing the sensitivity to changes in price action, making the signals come quicker but is more susceptible to quick fluctuations. A value of between (18-25) is reasonable for KC Length .
Style Setting
You may select if you want to see the buy and sell signals. The following 5 options Raw OBV Osc through Squeeze Momentum allow you to see where each specific requirement was met, posted as a vertical line, but for live use it is recommended to turn all of these vertical lines off and only use the buy and sell signals.
Time Frames:
While this script is most effective on shorter time frames (1 minute for scalping and daytrading) it is also viable to use it on longer timeframes, due to the nature of its components being independent of time frame.
Examples of use - (Green and red vertical lines are for visualization purpose and are not part of the script)
SPY 1 Minute (Factory Settings):
SPX 15 minutes (Factory Settings):
Considerations
This script is meant primarily for short term trading, trades on the basis of seconds to minutes primarily. While they can be a good indication of volume lining up with momentum, it is always wise to use them in combination with other factors such as support, resistance, market structure, volume levels, or the many other techniques out there...
As Always... Happy Trading.
-Not_A_Mad_Scientist (GreatfulFutures Trade University)
Empire OS Automated Trading • Institutional-grade executionEmpire OS – 9/40 EMA Dynamic Momentum Strategy
This strategy isn’t just EMAs — it’s a dynamic entry and exit system built around real-time price behavior. The 9/40 EMA setup gives the base trend direction, and the internal engine calculates every entry, stop, and target using recent price action and a 14-ATR volatility model.
Everything adjusts automatically:
• Entries react to momentum shifts based on the 9/40 EMA separation
• Stops tighten or widen based on the current 14-ATR reading
• Targets scale with real market volatility (not fixed numbers)
• Risk-to-Reward is calculated on the fly for cleaner, stronger trades
• Exits are based on structure + volatility, not random lines
Most strategies use fixed stops, fixed R:R, or standard EMA pairs that anyone can copy.
This one adapts to the market in real time — making every trade unique to current conditions.
It’s rare because almost nobody builds a retail strategy that:
Uses a non-standard 9/40 EMA combo
Calculates stops + targets off real volatility
Adjusts risk reward based on live price activity
Filters entries through momentum AND price structure
Keeps drawdown tight while catching high-quality moves
This is the official Empire OS version — built for consistency, momentum accuracy, and prop-firm scalability.
XAU BUY/SELL Scalping Strategy M5 PROFX:XAUUSD
This XAU/USD Pro Scalping Strategy is tailored specifically for the M5 timeframe , designed to capture rapid Gold price movements. Instead of relying on lagging indicators, this system utilizes advanced Price Action and Market Structure analysis to identify high-probability entry zones.
The core strength of this strategy lies in its built-in Money Management engine and Multi-threaded Trailing Stop system, ensuring capital preservation and profit maximization.
🚀 Key Features:
1. Smart Price Action Recognition:
The algorithm scans for specific market scenarios to apply dynamic Risk:Reward ratios (ranging from 1:1 to 1:3).
Filters out noise and false breakouts using multi-candle analysis.
Auto Position Sizing:
Calculates trade quantity automatically based on your defined Risk % per Trade .
Ensures consistent risk management regardless of the Stop Loss distance.
Intelligent Trailing Stop:
Uses a dynamic trailing mechanism based on "R" multiples (Risk Units).
Automatically secures profits by moving SL based on the specific setup type ("Case") of each trade.
Safety Filters:
Min SL and Max SL inputs prevent trades during periods of extremely low volatility or excessive risk.
⚙️ Settings:
Risk % per Trade: The percentage of equity to risk per trade (Recommended: 1.0% - 2.0%).
Min/Max SL Points: Dynamic boundaries for Stop Loss to adapt to current market volatility.
💡 Recommendations:
Symbol: XAUUSD / Gold - FXCM.
Timeframe: M5.
Best performance during London and New York sessions.






















