Waddah Attar Explosion [smillal]This is just a slightly altered version of Lazy Bear's great indicator
with the added feature to draw the explosion line in different colors while it is currently rising or falling.
Cerca negli script per "momentum"
BP Scalper with resistance barsThis Script is used for scalping on the 15 min. It can do the other time frames but i built it for primarily the 15. There is some logic where i use the previous candles and i'm using intervals of 4 to get 1 hour estimates. This also works with the 1 hour, because the 4 hour is what it will compare with.
It uses Buy volume and sell volume to create the indicators.
If the buy volume starts losing traction on the sell volume the indicator triggers.
JSE Market Breadth Stocks>MAThis indicator is for the Johannesburg Stock Exchange (JSE) and indicates the number of stocks in the Top 40 Index above its selected Smooth Moving Average (SMA). Typically the 200SMA is used to see the longer term health of the market and the 50SMA for a short term view. Currently the market has reached a point that less than 2% of stocks were above their 200SMA which is the lowest since 2013.
TrapTradingBuy on dips and sell into rallies. Simple as that.
- Short line (green)
- Base line (white)
- Long line (red)
When the market price touches the white or the red(green) lines, buy(sell) orders are generated.
The exit points are 2 lines above(below) the entries.
Parameters
- Period: It affects the value of Base line and the spacing of each line.
- Multiple: Specify the spacing between each line.
Frosted 12 EMA WIDTHThis is a complementary indicator for the 12 EMAs indicator ()
This width indicator shows the fanning width of each fan (shorter MAs and longer MAs).
To make things easier to see:
You can turn off one of the histograms to view just one of the widths (and add a 2nd instance of this indicator, turning off the other width).
B3 Directional Trend IndexB3 Directional Trend Index ~ All about the trend! William Blau is the designer of this gem, and IMHO it is the best trend finder of all the lagging indicators out there I have tested. It is important to pay attention to the slope and thickness of the line, and its relationship to zero. A reversion to the zero may look momentous, but in fact it could reverse when it reaches mean, only to turn back around. You can see this in March and April of this silver futures daily chart. Makes for a great instrument on anything you consider trendy, like crude oil for example. The default user inputs are set to my liking, as I find them to be great on all charts and resolutions. You may read around to find more about this on the internet, or its mentioned in Krausz's work. Also, imprtant to remember when no trend, trend finders like this sufffer, so be wise as to what market condition you are in. Rangy and within Range = no, On the Move = yes.
UCS_Momentum OscillatorI am not sure if someone else has already thought about it. But this is something I use to measure the meaningful oversold and overbought level, provided the stock is in a trend. I will add a Trend Indicator along with this in the next version.
I have added RSI, ROC, Stoch to compare. From the code below, i am using Stochastic, but the idea is same, if you use RSI. Experiment with your own comfortable time frames.
This is not a holy grail, The oversold and overbought in a trend transition period could be misleading. But over all, Its a good measure to trade overbought and oversold region
List of All my Indicators - www.tradingview.com
BACAP PRICE STRUCTURE 21 EMA TREND21dma-STRUCTURE
Overview
The 21dma-STRUCTURE indicator is a sophisticated overlay indicator that visualizes price action relative to a triple 21-period exponential moving average structure. Originally developed by BalarezoCapital and enhanced by PrimeTrading, this indicator provides clear visual cues for trend direction and momentum through dynamic bar coloring and EMA structure analysis.
Key Features
Triple EMA Structure
- 21 EMA High: Tracks the exponential moving average of high prices
- 21 EMA Close: Tracks the exponential moving average of closing prices
- 21 EMA Low: Tracks the exponential moving average of low prices
- Dynamic Cloud: Gray fill between high and low EMAs for visual structure reference
Smart Bar Coloring System
- Blue Bars: Price closes above all three EMAs (strong bullish momentum)
- Pink Bars: Daily high falls below the lowest EMA (strong bearish signal)
- Gray Bars: Neutral conditions or transitional phases
- Color Memory: Maintains previous color until new condition is met
Dynamic Center Line
- Trend-Following Color: Green when all EMAs are rising, red when all are falling
- Color Persistence: Maintains trend color during sideways movement
- Visual Clarity: Thicker center line for easy trend identification
Customizable Visual Elements
- Adjustable line thickness for all EMA plots
- Customizable colors for bullish and bearish conditions
- Configurable trend colors for uptrend and downtrend phases
- Optional bar color changes with toggle control
How to Use
Trend Identification
- Rising Green Center Line: All EMAs trending upward (bullish structure)
- Falling Red Center Line: All EMAs trending downward (bearish structure)
- Flat Center Line: Maintains last trend color during consolidation
Momentum Analysis
- Blue Bars: Strong bullish momentum with price above entire EMA structure
- Pink Bars: Strong bearish momentum with high below lowest EMA
- Gray Bars: Neutral or transitional momentum phases
Entry and Exit Signals
- Bullish Setup: Look for blue bars during green center line periods
- Bearish Setup: Look for pink bars during red center line periods
- Exit Consideration: Watch for color changes as potential momentum shifts
Structure Trading
- Support/Resistance: Use EMA cloud as dynamic support and resistance zones
- Breakout Confirmation: Bar color changes can confirm structure breakouts
- Trend Continuation: Color persistence suggests ongoing momentum
Settings
Visual Customization
- Change Bar Color: Toggle to enable/disable bar coloring
- Line Size: Adjust thickness of EMA lines (default: 3)
- Bullish Candle Color: Customize blue bar color
- Bearish Candle Color: Customize pink bar color
Trend Colors
- Uptrend Color: Color for rising EMA center line (default: green)
- Downtrend Color: Color for falling EMA center line (default: red)
- Cloud Color: Fill color between high and low EMAs (default: gray)
Advanced Features
Modified Bar Logic
Unlike traditional EMA systems, this indicator uses refined conditions:
- Bullish signals require close above ALL three EMAs
- Bearish signals require high below the LOWEST EMA
- Enhanced precision reduces false signals compared to single EMA systems
Trend Memory System
- Intelligent color persistence during sideways movement
- Reduces noise from minor EMA fluctuations
- Maintains trend context during consolidation periods
Performance Optimization
- Efficient calculation methods for real-time performance
- Clean visual design that doesn't clutter charts
- Compatible with all timeframes and instruments
Best Practices
Multi-Timeframe Analysis
- Use higher timeframes to identify overall trend direction
- Apply on multiple timeframes for confluence
- Combine with weekly/monthly charts for position trading
Risk Management
- Use bar color changes as early warning signals
- Consider position sizing based on EMA structure strength
- Set stops relative to EMA support/resistance levels
Combination Strategies
- Pair with volume indicators for confirmation
- Use alongside RSI or MACD for momentum confirmation
- Combine with key support/resistance levels
Market Context
- More effective in trending markets than choppy conditions
- Consider overall market environment and sector strength
- Adjust expectations during high volatility periods
Technical Specifications
- Based on 21-period exponential moving averages
- Uses Pine Script v6 for optimal performance
- Overlay indicator that works with any chart type
- Maximum 500 lines for clean performance
Ideal Applications
- Swing trading on daily charts
- Position trading on weekly charts
- Intraday momentum trading (adjust timeframe accordingly)
- Trend following strategies
- Structure-based trading approaches
Disclaimer
This indicator is for educational and informational purposes only. It should not be used as the sole basis for trading decisions. Always combine with other forms of analysis, proper risk management, and consider your individual trading plan and risk tolerance.
Compatible with Pine Script v6 | Works on all timeframes | Optimized for trending markets
My script//@version=5
indicator("XAUUSD High Win-Rate Strategy", shorttitle="XAUUSD HWR", overlay=true)
// ============================================================================
// XAUUSD HIGH WIN-RATE STRATEGY INDICATOR
// Based on Dual-Phase Momentum Filter System
// Designed for M1, M5 timeframes with H1/H4 bias confirmation
// ============================================================================
// Input Parameters
ma_length = input.int(55, title="MA Channel Length", minval=1, maxval=200)
atr_length = input.int(14, title="ATR Length", minval=1, maxval=50)
atr_multiplier = input.float(2.5, title="ATR Stop Loss Multiplier", minval=1.0, maxval=5.0, step=0.1)
rr_ratio = input.float(1.5, title="Risk:Reward Ratio", minval=1.0, maxval=3.0, step=0.1)
htf_bias = input.timeframe("60", title="Higher Timeframe for Bias")
show_levels = input.bool(true, title="Show Entry/Exit Levels")
show_signals = input.bool(true, title="Show Buy/Sell Signals")
show_channel = input.bool(true, title="Show MA Channel")
// ============================================================================
// CORE CALCULATIONS
// ============================================================================
// Moving Average Channel (55-period High/Low)
ma_high = ta.sma(high, ma_length)
ma_low = ta.sma(low, ma_length)
// Heiken Ashi Calculations
ha_close = (open + high + low + close) / 4
var float ha_open = na
ha_open := na(ha_open ) ? (open + close) / 2 : (ha_open + ha_close ) / 2
ha_high = math.max(high, math.max(ha_open, ha_close))
ha_low = math.min(low, math.min(ha_open, ha_close))
// Higher Timeframe Bias (200 SMA)
htf_sma200 = request.security(syminfo.tickerid, htf_bias, ta.sma(close, 200), lookahead=barmerge.lookahead_off)
// ATR for Stop Loss Calculation
atr = ta.atr(atr_length)
// RSI for Additional Confirmation
rsi = ta.rsi(close, 14)
// ============================================================================
// SIGNAL LOGIC
// ============================================================================
// Channel Filter - No trades when price is within the channel
in_channel = close > ma_low and close < ma_high
outside_channel = not in_channel
// Heiken Ashi Color
ha_bullish = ha_close > ha_open
ha_bearish = ha_close < ha_open
// Higher Timeframe Bias
htf_bullish = close > htf_sma200
htf_bearish = close < htf_sma200
// Entry Conditions
long_condition = outside_channel and close > ma_high and ha_bullish and htf_bullish
short_condition = outside_channel and close < ma_low and ha_bearish and htf_bearish
// Entry Signals (only on bar close to avoid repainting)
long_signal = long_condition and not long_condition
short_signal = short_condition and not short_condition
// ============================================================================
// TRADE LEVELS CALCULATION
// ============================================================================
var float entry_price = na
var float stop_loss = na
var float take_profit = na
var string trade_direction = na
// Calculate levels for new signals
if long_signal
entry_price := close
stop_loss := close - (atr * atr_multiplier)
take_profit := close + ((close - stop_loss) * rr_ratio)
trade_direction := "LONG"
if short_signal
entry_price := close
stop_loss := close + (atr * atr_multiplier)
take_profit := close - ((stop_loss - close) * rr_ratio)
trade_direction := "SHORT"
// ============================================================================
// VISUAL ELEMENTS
// ============================================================================
// MA Channel - Store plot IDs for fill function
ma_high_plot = plot(show_channel ? ma_high : na, color=color.blue, linewidth=1, title="MA High")
ma_low_plot = plot(show_channel ? ma_low : na, color=color.red, linewidth=1, title="MA Low")
// Fill the channel
fill(ma_high_plot, ma_low_plot, color=color.new(color.gray, 90), title="MA Channel")
// Higher Timeframe SMA200
plot(htf_sma200, color=color.purple, linewidth=2, title="HTF SMA200")
// Entry Signals
plotshape(show_signals and long_signal, title="Long Signal", location=location.belowbar,
style=shape.triangleup, size=size.normal, color=color.green)
plotshape(show_signals and short_signal, title="Short Signal", location=location.abovebar,
style=shape.triangledown, size=size.normal, color=color.red)
// Trade Levels
entry_plot = plot(show_levels and not na(entry_price) ? entry_price : na,
color=color.yellow, linewidth=2, style=line.style_dashed, title="Entry Price")
stop_plot = plot(show_levels and not na(stop_loss) ? stop_loss : na,
color=color.red, linewidth=2, style=line.style_dotted, title="Stop Loss")
target_plot = plot(show_levels and not na(take_profit) ? take_profit : na,
color=color.green, linewidth=2, style=line.style_dotted, title="Take Profit")
// ============================================================================
// ALERTS
// ============================================================================
// Alert Conditions
alertcondition(long_signal, title="Long Entry Signal",
message="XAUUSD Long Entry: Price={{close}}, SL=" + str.tostring(stop_loss) + ", TP=" + str.tostring(take_profit))
alertcondition(short_signal, title="Short Entry Signal",
message="XAUUSD Short Entry: Price={{close}}, SL=" + str.tostring(stop_loss) + ", TP=" + str.tostring(take_profit))
// ============================================================================
// INFORMATION TABLE
// ============================================================================
if barstate.islast and show_levels
var table info_table = table.new(position.top_right, 2, 8, bgcolor=color.white, border_width=1)
table.cell(info_table, 0, 0, "XAUUSD Strategy Info", text_color=color.black, text_size=size.normal)
table.cell(info_table, 1, 0, "", text_color=color.black)
table.cell(info_table, 0, 1, "Current Price:", text_color=color.black)
table.cell(info_table, 1, 1, str.tostring(close, "#.##"), text_color=color.black)
table.cell(info_table, 0, 2, "ATR (14):", text_color=color.black)
table.cell(info_table, 1, 2, str.tostring(atr, "#.##"), text_color=color.black)
table.cell(info_table, 0, 3, "RSI (14):", text_color=color.black)
table.cell(info_table, 1, 3, str.tostring(rsi, "#.##"), text_color=color.black)
table.cell(info_table, 0, 4, "HTF Bias:", text_color=color.black)
table.cell(info_table, 1, 4, htf_bullish ? "BULLISH" : "BEARISH",
text_color=htf_bullish ? color.green : color.red)
table.cell(info_table, 0, 5, "In Channel:", text_color=color.black)
table.cell(info_table, 1, 5, in_channel ? "YES" : "NO",
text_color=in_channel ? color.red : color.green)
if not na(trade_direction)
table.cell(info_table, 0, 6, "Last Signal:", text_color=color.black)
table.cell(info_table, 1, 6, trade_direction,
text_color=trade_direction == "LONG" ? color.green : color.red)
table.cell(info_table, 0, 7, "Risk/Reward:", text_color=color.black)
table.cell(info_table, 1, 7, "1:" + str.tostring(rr_ratio, "#.#"), text_color=color.black)
// ============================================================================
// BACKGROUND COLORING
// ============================================================================
// Color background based on trend and channel status
bg_color = color.new(color.white, 100)
if htf_bullish and not in_channel
bg_color := color.new(color.green, 95)
else if htf_bearish and not in_channel
bg_color := color.new(color.red, 95)
else if in_channel
bg_color := color.new(color.yellow, 95)
bgcolor(bg_color, title="Background Trend Color")
// ============================================================================
// STRATEGY NOTES
// ============================================================================
// This indicator implements the Dual-Phase Momentum Filter System:
// 1. MA Channel Filter: Avoids trades when price is between 55-period high/low MAs
// 2. Heiken Ashi Confirmation: Requires momentum alignment for entries
// 3. Higher Timeframe Bias: Uses 200 SMA on higher timeframe for direction
// 4. ATR-based Risk Management: Dynamic stop losses based on volatility
// 5. Fixed Risk:Reward Ratio: Consistent 1:1.5 profit targets
//
// Usage Instructions:
// 1. Apply to M1 or M5 timeframe for optimal signals
// 2. Set higher timeframe to H1 or H4 for bias confirmation
// 3. Wait for signals outside the MA channel
// 4. Enter trades only when all conditions align
// 5. Use provided stop loss and take profit levels
// 6. Risk no more than 0.5% of account per trade
//
// Best Trading Sessions: Asian and New York
// Avoid: Low liquidity periods and major news events
VWAP & MVWAP Cross [Dr.K.C.Prakash]The indicator "VWAP & MVWAP Cross (20)" is a custom-built Pine Script-based trading tool designed for precision intraday trading, especially useful in fast-moving markets like options or indices on the 1-minute or 5-minute timeframes.
🔍 Core Concept
This indicator uses two key components:
VWAP (Volume Weighted Average Price)
VWAP is a dynamic intraday average that reflects the average price weighted by volume.
It resets every trading day, providing real-time insight into institutional trading levels.
MVWAP (Moving VWAP or Multi-session VWAP)
MVWAP typically refers to a smoothed or multi-timeframe version of VWAP.
It reduces noise and captures more sustained directional trends, often calculated using a moving average over the VWAP values.
⚙️ Technical Mechanics
Buy Signal: Triggered when the VWAP crosses above the MVWAP, indicating bullish strength and potential upward momentum.
Sell Signal: Triggered when the VWAP crosses below the MVWAP, suggesting bearish momentum.
Each crossover is treated as a significant shift in price behavior, often confirming the start of a short-term trend.
📈 Features
🔵 Buy and 🔴 Sell Signals: Clear visual markers are placed directly on the chart.
📊 Real-Time Labels: "BUY" or "SELL" labels appear at cross-points.
🧭 Noise Filtering: Short, false reversals are filtered out using logic that prioritizes long, stable trends (based on your previous customization preferences).
🕐 1-Minute Optimization: This version is particularly calibrated for 1-minute timeframe, useful for scalping or option buying.
✅ Use Cases
Scalping strategies
Index or Option intraday trading
Detecting institutional entry/exit zones
Momentum confirmation alongside price action or ATR levels
📌 Customizations by Dr.K.C.Prakash
Emphasis on long-trend clarity, removing short noise.
Adjusted smoothing on MVWAP for more reliable entries.
Built with visual clarity and minimal lag for professional-grade decision-making.
21DMA Structure Counter (EMA/SMA Option)21DMA Structure Counter (EMA/SMA Option)
Overview
The 21DMA Structure Counter is an advanced technical indicator that tracks consecutive periods where price action remains above a 21-period moving average structure. This indicator helps traders identify momentum phases and potential trend exhaustion points using statistical analysis.
Key Features
Moving Average Structure
- Configurable MA Type: Choose between EMA (Exponential Moving Average) or SMA (Simple Moving Average)
- 21-Period Default: Optimized for the widely-watched 21-period moving average
- Triple MA Structure: Tracks high, close, and low moving averages for comprehensive analysis
Statistical Analysis
- Cycle Counting: Automatically counts consecutive periods above the MA structure
- Historical Data: Maintains up to 2,500 historical cycles (approximately 10 years of daily data)
- Z-Score Calculation: Provides statistical context using mean and standard deviation
- Multiple Standard Deviation Levels: Displays +1, +2, and +3 standard deviation thresholds
Visual Indicators
Color-Coded Bars:
- Gray: Below 10-year average
- Yellow: Between average and +1 standard deviation
- Orange: Between +1 and +2 standard deviations
- Red: Between +2 and +3 standard deviations
- Fuchsia: Above +3 standard deviations (extreme readings)
Breadth Integration
- Multiple Breadth Options: NDFI, NDTH, NDTW (NASDAQ breadth indicators), or VIX
- Background Shading: Visual alerts when breadth reaches extreme levels
- High/Low Thresholds: Customizable levels for breadth analysis
- Real-time Display: Current breadth value shown in data table
Smart Reset Logic
- High Below Structure Reset: Automatically resets count when daily high falls below the lowest MA
- Flexible Hold Period: Continues counting during temporary weakness as long as structure isn't violated
- Precise Entry/Exit: Strict criteria for starting cycles, flexible for maintaining them
How to Use
Trend Identification
- Rising Counts: Indicate sustained momentum above key moving average structure
- Extreme Readings: Z-scores above +2 or +3 suggest potential trend exhaustion
- Historical Context: Compare current cycles to 10-year statistical averages
Risk Management
- Breadth Confirmation: Use breadth shading to confirm market-wide strength/weakness
- Statistical Extremes: Exercise caution when readings reach +3 standard deviations
- Reset Signals: Pay attention to structure violations for potential trend changes
Multi-Timeframe Application
- Daily Charts: Primary timeframe for swing trading and position management
- Weekly/Monthly: Longer-term trend analysis
- Intraday: Shorter-term momentum assessment (adjust MA period accordingly)
Settings
Moving Average Options
- Type: EMA or SMA selection
- Period: Default 21 (customizable)
- Reset Days: Days below structure required for reset
Visual Customization
- Standard Deviation Lines: Toggle and customize colors for +1, +2, +3 SD
- Breadth Selection: Choose from NDFI, NDTH, NDTW, or VIX
- Threshold Levels: Set custom high/low breadth thresholds
- Table Styling: Customize text colors, background, and font size
Technical Notes
- Data Retention: Maintains 2,500 historical cycles for robust statistical analysis
- Real-time Updates: Calculations update with each new bar
- Breadth Integration: Uses security() function to pull external breadth data
- Performance Optimized: Efficient array management prevents memory issues
Best Practices
1. Combine with Price Action: Use alongside support/resistance and chart patterns
2. Monitor Breadth Divergences: Watch for breadth weakness during strong readings
3. Respect Statistical Extremes: Exercise caution at +2/+3 standard deviation levels
4. Context Matters: Consider overall market environment and sector rotation
5. Risk Management: Use appropriate position sizing, especially at extreme readings
Disclaimer
This indicator is for educational and informational purposes only. It should not be used as the sole basis for trading decisions. Always combine with other forms of analysis and proper risk management techniques.
Compatible with Pine Script v6 | Optimized for daily timeframes | Best used on major indices and liquid stocks
ALEX - ATR Extensions + ADR + TableALEX - ATR Extensions + ADR + Table
Overview
The ALEX ATR Extensions indicator is a comprehensive volatility and momentum analysis tool that combines Average True Range (ATR), Average Daily Range (ADR), and moving average distance calculations in a single, customizable display. This indicator helps traders assess current price action relative to historical volatility and key moving averages, providing crucial context for risk management and trade planning.
Key Features
Multi-Metric Analysis
- ATR Percentage: Current ATR as a percentage of price for volatility assessment
- ADR Percentage: Average Daily Range as a percentage for typical daily movement
- Low of Day Distance: Distance from current price to daily low
- Moving Average Distance: ATR-normalized distance from 21 and 50 period moving averages
Flexible Moving Average Options
- Configurable MA Types: Choose between EMA or SMA for both 21 and 50 period averages
- Customizable Periods: Adjust moving average lengths to suit your trading style
- Daily Timeframe Data: Uses daily moving averages regardless of chart timeframe
ATR Extension Levels
- Dynamic Price Targets: Calculate extension levels based on ATR multiples from moving averages
- Visual Reference Lines: Optional overlay lines showing ATR extension targets
- Customizable Multipliers: Adjust ATR multipliers for different risk/reward scenarios
Smart Visual Alerts
- Color-Coded Distance Metrics: Automatic color changes based on distance thresholds
- Symbol Plotting: Customizable chart symbols when distance thresholds are exceeded
- Threshold-Based Alerts: Visual cues when price reaches significant ATR distances
Comprehensive Data Table
- Real-Time Metrics: Live updating table with all key measurements
- Customizable Display: Toggle individual metrics on/off based on preference
- Professional Styling: Adjustable colors, fonts, and transparency
How to Use
Volatility Assessment
- High ATR%: Indicates elevated volatility, larger position sizing considerations
- Low ATR%: Suggests compressed volatility, potential for expansion
- ADR% Comparison: Compare current day's range to historical average
Moving Average Analysis
- ATR Distance 21/50: Normalized distance showing how extended price is from key levels
- Positive Values: Price above moving average (bullish positioning)
- Negative Values: Price below moving average (bearish positioning)
- Color Changes: Automatic alerts when reaching threshold levels
Extension Target Planning
- ATR Extension Lines: Visual price targets based on volatility-adjusted projections
- Risk/Reward Planning: Use extension levels for profit target placement
- Breakout Confirmation: Extension levels can confirm breakout validity
Symbol Alert System
- Chart Symbols: Automatic plotting when distance thresholds are breached
- Customizable Triggers: Set your own threshold levels for alerts
- Visual Scanning: Quick identification of extended conditions across multiple charts
Settings
Display Controls
- Show ADR%: Toggle average daily range percentage display
- Show ATR%: Toggle average true range percentage display
- Show LoD Distance: Toggle low of day distance calculation
- Show LoD Price: Toggle actual low of day price display
- Show ATR Distance from 21/50 DMA: Toggle moving average distance metrics
- Show 21/50 DMA Price: Toggle actual moving average price display
- Show ATR Extension Levels: Toggle extension target display in table
Moving Average Configuration
- 21/50 DMA Type: Choose between EMA or SMA calculation methods
- 21/50 DMA Period: Customize moving average lengths
- ADR/ATR Length: Adjust calculation periods for range measurements
Color Thresholds
- Threshold Levels: Set distance levels for color changes (default 2.0 and 5.0)
- Custom Colors: Choose colors for different threshold breaches
- Separate 21/50 Settings: Independent color schemes for each moving average
Symbol Settings
- Show Char Symbol: Toggle symbol plotting for each moving average
- Custom Symbols: Choose any character for chart plotting
- Symbol Colors: Customize colors for visual distinction
- Threshold Levels: Set trigger points for symbol appearance
ATR Extension Lines
- Show Extension Lines: Toggle visual extension level lines
- ATR Multipliers: Customize extension distance (default 2.0x)
- Line Colors: Choose colors for extension level visualization
Table Customization
- Background Color: Adjust table transparency and color
- Text Color: Customize default text appearance
- Font Size: Choose from tiny to huge font options
Advanced Applications
Trend Strength Analysis
- Large ATR distances suggest strong trending moves
- Small ATR distances indicate potential consolidation or reversal zones
- Compare current readings to recent historical ranges
Risk Management
- Use ATR% for position sizing calculations
- Extension levels provide natural profit target zones
- Distance metrics help identify overextended conditions
Multi-Timeframe Context
- Apply to different timeframes for comprehensive analysis
- Daily data provides consistency across all chart intervals
- Combine with weekly/monthly analysis for broader context
Market Regime Identification
- High volatility periods: Increased ATR% readings
- Low volatility periods: Compressed ATR% readings
- Trending markets: Sustained high distance readings
- Consolidating markets: Low distance readings with frequent color changes
Best Practices
Volatility-Adjusted Trading
- Increase position sizes during low volatility periods
- Reduce position sizes during high volatility periods
- Use ATR% for stop-loss placement relative to normal market movement
Extension Level Usage
- Primary targets: 1.5-2.0x ATR extensions
- Secondary targets: 2.5-3.0x ATR extensions
- Avoid chasing prices beyond 3x ATR extensions
Threshold Optimization
- Backtest different threshold levels for your trading style
- Consider market conditions when setting alert levels
- Adjust thresholds based on instrument volatility characteristics
Integration Strategies
- Combine with momentum indicators for confirmation
- Use alongside support/resistance levels
- Incorporate into systematic trading approaches
Technical Specifications
- Compatible with Pine Script v6
- Uses daily timeframe data for consistency
- Optimized for real-time performance
- Works on all chart types and timeframes
- Supports all tradeable instruments
Ideal For
- Swing traders using daily charts
- Position traders seeking volatility context
- Day traders needing intraday reference levels
- Risk managers requiring volatility metrics
- Systematic traders building rule-based strategies
Disclaimer
This indicator is for educational and informational purposes only. It should not be used as the sole basis for trading decisions. Always combine with other forms of analysis, proper risk management techniques, and consider your individual trading plan and risk tolerance. Past performance does not guarantee future results.
Compatible with Pine Script v6 | Optimized for daily timeframe analysis | Works across all markets and instruments
Double Smoothed MomentaDouble Smoothed Momenta was created by William Blau (Stocks & Commodities V. 9:5 (202-205)). His original indicator didn't use a signal period so I added one to notify you when to buy or sell. Buy when the indicator goes over the signal line and sell when it is falls below the signal line.
Let me know what other indicators you would like me to write scripts for!
Improved Stoch RSI + Supertrend Filter + ATR SL/TPThis custom indicator, "Improved Stoch RSI + Supertrend Filter + ATR SL/TP," is a powerful tool designed to generate high-probability trading signals in trending markets. It combines three technical indicators:
1. **Stochastic RSI** – Provides overbought and oversold signals by calculating the stochastic of the RSI, which helps identify momentum reversals.
2. **Supertrend Filter** – A trend-following indicator that filters signals to only trade in the direction of the current trend, reducing false signals and improving overall accuracy.
3. **ATR-based Stop-Loss and Take-Profit** – Uses the Average True Range (ATR) multiplied by a 1.5 factor to set dynamic stop-loss levels, and calculates take-profit levels based on a configurable Risk-Reward Ratio (default: 1.5).
**How it works:**
* When the %K line of the Stochastic RSI crosses above the %D line below the oversold level (default: 20), and the Supertrend indicates an uptrend, a **long trade signal** is generated.
* When the %K line of the Stochastic RSI crosses below the %D line above the overbought level (default: 80), and the Supertrend indicates a downtrend, a **short trade signal** is generated.
* Each trade signal comes with a plotted stop-loss and take-profit level based on the ATR, giving you predefined risk management points.
This indicator helps traders:
* Trade only with the prevailing trend
* Identify reversal points with high accuracy
* Manage risk consistently with ATR-based stop-loss and take-profit
It's suitable for all timeframes and can be used as a standalone system or to complement other trading strategies.
RSI Missmatch(Divergence) OSC. by Neo_ with Missmatch Alert█ Definition
A divergence or missmatch occurs when an asset’s price is moving opposite to a specific technical indicator or is moving in a different direction from other relevant data. The divergence indicator warns traders and technical analysts of changes in a price trend, oftentimes that it is weakening or changing direction.
Divergence or missmatch can be either positive, signifying the possibility of a move that is higher in the asset’s price, or it can be negative, signifying the possibility of a move that is lower in the asset’s price.
█ Takeaways
Divergence or missmatch often works with other indicators and data. It is usually used by technical analysts and traders when the asset’s price is moving counter to the direction of another indicator.
As mentioned above, positive divergence or missmatch indicates that the price could start rising and usually occurs when the price is moving lower, but while another indicator counters this direction by moving higher. In other words, showing bullish signals.
Negative divergence or missmatch indicates that the price could start declining and usually occurs when the price is moving higher, while another indicator moves lower as well. In other words, showing bearish signals.
█ What to look for
Divergence or missmatch is most often used to track and analyze the momentum in an asset’s price and the odds of a price reversal within the current trend. While using divergence, traders and analysts can decide on whether or not they would like to exit the position or set a stop loss in the case the divergence is negative and prices begin to fall.
█ Limitations
It is best to use divergence or missmatch with the aid of other indicators and analysis tools in order to help identify and confirm trend reversals and major market patterns. Divergence should not be relied on by itself to tell you the pertinent information you need to know as an investor. Risk control is key in your analysis and the fact that divergence is not always present in price reversals should definitely be what pushes you to combine it with other tools and indicators.
Additionally, divergence or missmatch can reflect long-term or short-term changes. When making snap decisions, acting on divergence alone could prove detrimental to your trading. Make sure you have other risk factors applied to your charting and general market analysis.
█ What exactly is RSI Missmatches discrepancies using a lookback period in trading?
In trading, lookback period is the number of periods of historical data used for observation and calculation. It is how far into the past the system looks when trying to calculate the variable under consideration. The concept was based on the fact that history can provide information about the future, and my aim was to predict the periods when trend changes would begin within these periods with the RSI oscillator. But this is only true if you're locked back far enough, not locked any further or less!
We already use the idea of looking back in different aspects of our lives, and even in the world of financial trading it can be used in various ways. Of course you will want to learn more about the concept, so in this article we will cover the following topics:
█ What kind of hindsight is this?
The aim here is to check whether trends will change in certain cycles, so we chose the High + Low / 2 formula as the source. Because no matter how much the prices swing up or down, sometimes the rebound can go further. The aim here is to notice the points where the price leaves a needle at the levels where it oscillates and the slowdown in momentum.
█ What does look-back period mean in trade?
To understand what a lookback period means in trading, you need to ask yourself: What is a lookback period in trading? In financial trading, period refers to the duration of a particular trading session. For example, a one-week period means one full week of trading sessions or five trading days. In 5 trading days, the average time is 120 hours in FX markets and 40 hours in stock markets. Regardless of what happens in these cycles, I prefer to choose a time period of 55 periods. Because I noticed that in all the charts I examined, the cycles generally changed during this time period.
█ Let's talk about the meaning of catching Missmatches
As you know, technical indicators are all a mathematical calculation using historical market data (price, volume, or a combination of both). It shows the behavior of the price better and helps in the analysis of price movement. But the indicator can only serve your intended purpose if you get the lookback time right. What we mean here is the setting parameter that determines how much historical data it will use in its calculation. In other words, it is the retrospective review period.
For example, on the RSI indicator you can set this period to 13 periods (default setting) or even 2 periods. The period you choose can determine what the indicator tells you, which in turn determines the strategy you can create with the indicator. The 13- period RSI gives you information about price momentum, so you can effectively use it to create a momentum strategy. On the other hand, the 2-periods RSI can be used to create a mean reversion strategy. To catch any incompatibilities, I set this period to 55 periods. Nothing more, nothing less!
█ Summary
The missmatch indicator helps traders assess changes in the price trend and indicates when price will move with or against the direction of another indicator. It can be either positive or negative, but it is important to note its limitations and that it should be used with other indicators that can also monitor price trends.
We wish you to identify these incompatibilities in the market in the best way possible... Good luck.
█ Tanım
Bir varlığın fiyatı belirli bir teknik göstergenin tersi yönünde hareket ettiğinde veya diğer ilgili verilerden farklı bir yönde hareket ettiğinde bir sapma veya uyumsuzluk meydana gelir. Farklılık göstergesi, tüccarları ve teknik analistleri fiyat eğilimindeki değişiklikler konusunda uyarır; çoğu zaman zayıflıyor veya yön değiştiriyor.
Farklılık veya uyumsuzluk, varlığın fiyatında daha yüksek bir hareket olasılığını işaret ederek pozitif olabilir veya varlığın fiyatında daha düşük bir hareket olasılığını işaret ederek negatif olabilir.
█ Çıkarımlar
Farklılık veya uyumsuzluk çoğu zaman diğer göstergeler ve verilerle de çalışır. Genellikle teknik analistler ve yatırımcılar tarafından varlığın fiyatı başka bir göstergenin yönünün tersine hareket ettiğinde kullanılır.
Yukarıda bahsedildiği gibi pozitif sapma veya uyumsuzluk, fiyatın yükselmeye başlayabileceğini gösterir ve genellikle fiyat düşerken meydana gelir, ancak başka bir gösterge bu yöne yükselerek karşı koyar. Başka bir deyişle yükseliş sinyalleri veriyor.
Negatif sapma veya uyumsuzluk, fiyatın düşmeye başlayabileceğini gösterir ve genellikle fiyat yükselirken başka bir gösterge de düşerken meydana gelir. Başka bir deyişle düşüş sinyalleri veriyor.
█ Nelere bakılmalı
Farklılık veya uyumsuzluk çoğunlukla bir varlığın fiyatındaki momentumu ve mevcut trend içinde fiyatın tersine dönme olasılığını izlemek ve analiz etmek için kullanılır. Farklılaşmayı kullanırken tüccarlar ve analistler, sapmanın negatif olması ve fiyatların düşmeye başlaması durumunda pozisyondan çıkmak isteyip istemeyeceklerine veya zararı durdurma kararı verip veremeyeceklerine karar verebilirler.
█ Sınırlamalar
Trend dönüşlerini ve ana piyasa modellerini tanımlamaya ve doğrulamaya yardımcı olmak için diğer göstergeler ve analiz araçlarının yardımıyla sapmayı veya uyumsuzluğu kullanmak en iyisidir. Bir yatırımcı olarak bilmeniz gereken ilgili bilgileri size söylemesi için farklılığa tek başına güvenilmemelidir. Risk kontrolü analizinizin anahtarıdır ve fiyat dönüşlerinde farklılığın her zaman mevcut olmaması gerçeği kesinlikle sizi onu diğer araç ve göstergelerle birleştirmeye iten şey olmalıdır.
Ek olarak, farklılık veya uyumsuzluk uzun vadeli veya kısa vadeli değişiklikleri yansıtabilir. Ani kararlar verirken yalnızca farklılıklara göre hareket etmek ticaretinize zarar verebilir. Grafiğinize ve genel piyasa analizinize başka risk faktörlerinin uygulandığından emin olun.
█ Ticarette yeniden inceleme dönemi kullanan RSI Missmatches tutarsızlıkları tam olarak nedir?
Ticarette yeniden inceleme süresi, gözlem ve hesaplama için kullanılan geçmiş verilerin dönemlerinin sayısıdır. Söz konusu değişkeni hesaplamaya çalışırken sistemin ne kadar geçmişe baktığıdır. Konsept tarihin geleceğe dair bilgi verebileceği gerçeği üzerine kuruluydu ve amacım RSI osilatörü ile bu dönemler içerisinde trend değişimlerinin başlayacağı dönemleri tahmin etmekti. Ancak bu yalnızca yeterince geriye kilitlenmişseniz geçerlidir, daha fazla veya daha az kilitlenmemişseniz!
Geriye bakma fikrini hayatımızın farklı yönlerinde zaten kullanıyoruz ve hatta finansal ticaret dünyasında bile bu fikir çeşitli şekillerde kullanılabilir. Elbette konsept hakkında daha fazla bilgi edinmek isteyeceksiniz, bu nedenle bu yazıda aşağıdaki konuları ele alacağız:
█ Bu nasıl bir sonradan görmedir?
Burada amaç belli döngülerde trendlerin değişip değişmeyeceğini kontrol etmek olduğundan kaynak olarak Yüksek + Düşük / 2 formülünü seçtik. Çünkü fiyatlar ne kadar yukarı veya aşağı hareket ederse etsin bazen toparlanma daha da ileri gidebiliyor. Burada amaç fiyatın salınım yaptığı seviyelerde iğne bıraktığı noktaları ve momentumdaki yavaşlamayı fark etmektir.
█ Ticarette geriye bakma süresi ne anlama geliyor?
Ticarette yeniden inceleme süresinin ne anlama geldiğini anlamak için kendinize şu soruyu sormanız gerekir: Ticarette yeniden inceleme süresi nedir? Finansal ticarette dönem, belirli bir ticaret seansının süresini ifade eder. Örneğin, bir haftalık dönem, bir tam haftalık işlem seansı veya beş işlem günü anlamına gelir. 5 işlem gününde ortalama süre döviz piyasalarında 120 saat, borsalarda ise 40 saattir. Bu döngülerde ne olursa olsun 55 periyotluk bir zaman dilimini seçmeyi tercih ediyorum. Çünkü incelediğim tüm grafiklerde bu zaman diliminde döngülerin genel olarak değiştiğini fark ettim.
█ Kaçak Eşleşmeleri yakalamanın anlamı hakkında konuşalım
Bildiğiniz gibi teknik göstergeler, geçmiş piyasa verileri (fiyat, hacim veya her ikisinin birleşimi) kullanılarak yapılan matematiksel hesaplamalardır. Fiyatın davranışını daha iyi gösterir ve fiyat hareketinin analizine yardımcı olur. Ancak gösterge yalnızca yeniden inceleme süresini doğru yaparsanız amacınıza hizmet edebilir. Burada kast ettiğimiz, hesaplamasında ne kadar geçmiş veri kullanacağını belirleyen ayar parametresidir. Bir başka deyişle geriye dönük inceleme dönemidir.
Örneğin RSI göstergesinde bu süreyi 13 döneme (varsayılan ayar) ve hatta 2 döneme ayarlayabilirsiniz. Seçeceğiniz dönem, göstergenin size ne söyleyeceğini belirleyebilir ve bu da gösterge ile oluşturabileceğiniz stratejiyi belirler. 13 dönemlik RSI size fiyat momentumu hakkında bilgi verir, böylece onu bir momentum stratejisi oluşturmak için etkili bir şekilde kullanabilirsiniz. Öte yandan, ortalamaya dönüş stratejisi oluşturmak için 2 dönemlik RSI kullanılabilir. Herhangi bir uyumsuzluğu yakalamak için bu periyodu 55 periyoda ayarladım. Ne fazla ne eksik!
█ Özet
Uyumsuzluk göstergesi, yatırımcıların fiyat eğilimindeki değişiklikleri değerlendirmesine yardımcı olur ve fiyatın ne zaman başka bir göstergenin yönüne göre veya ona karşı hareket edeceğini gösterir. Olumlu ya da olumsuz olabilir, ancak sınırlamalarına dikkat etmek ve fiyat eğilimlerini de izleyebilecek diğer göstergelerle birlikte kullanılması gerektiğini unutmamak önemlidir.
Piyasadaki bu uyumsuzlukları en iyi şekilde tespit etmenizi dileriz... Bol Kazançlar.
Vigilant Asset Allocation G4 Backtesting EngineThis script was based off of an idea that @CubanEmissary had so the description and some of the code that @CubanEmissary built on TradingView was used.
Vigilant Asset Allocation G4 (VAA G4) is a dual-momentum based investment strategy that aggressively monitors the market and reallocates portfolio funds based on the relative momentums of user-defined risk assets and safety assets. It was created by Wouter Keller and JW Keuning, based on their paper "Breadth Momentum and Vigilant Asset Allocation." In contrast to traditional dual momentum strategies, VAA G4 monitors the market itself through the two asset types. When all risk assets have positive momentum, the portfolio is allocated entirely into the risk asset with the strongest momentum At any other time, the portfolio is allocated entirely into the safety asset with the strongest momentum. The combination of breadth momentum with a very defensive reallocation trigger results in a strategy which captures alpha consistently.
The Strategy Rules:
1. Calculate each asset's momentum score on each monthly close:
momentumScore = (12*(currentMonthlyClose/lastMonthlyClose))+(4*(currentMonthlyClose/thirdLastMonthlyClose))+(2*(currentMonthlyClose/sixthLastMonthlyClose))+(currentMonthlyClose/twelvethLastMonthlyClose)-19
2. If all risk asset momentums are positive, allocate entire portfolio to the risk asset with the strongest momentum.
3. If any risk asset's momentum is negative, allocate entire portfolio to the safety asset with the strongest momentum.
4. Reevaluate at the end of each month.
Caveats:
1. It seems like TradingView only has limited price data for these tickers that are listed in the strategy. So it is best to start the strategy when they all have ample data (~ June 2nd, 2008)
2. This backtesting engine is basic and doesn't account for slippage and trading fees. So I implemented a basic "trading fee" input that will subtract a trading fee whenever the strategy makes a trade at the end of the month.
3. It is assumed in this engine that the trades will be made the exact second a new monthly bar opens up.
4. MUST USE ON MONTHLY CHART. It is hard-coded to work on monthly chart, if you open it on a daily chart , the Sharpe, Sortino, & CAGR calculations might not be right as well as the momentum score