Поиск скриптов по запросу "daily"
Daily Returns & STDWhat happened last time when xx increased by xx%? - Start collecting some stats!
You can choose the ticker and the timeframe you're interested in
RSI Oversold/UndersoldThe study script will place GREEN BUY arrows BELOW oversold conditions and RED SHORT arrows ABOVE overbought conditions. You can configure the period
Most RSI(14) indicators use a 14-period, I prefer a 5-period. The period, overbought and oversold periods are settings that can easily be changed by adding this study to your chart and clicking the "gear" icon next to the study inside your chart.
Daily SMAThis pine script on intraday chart is exactly the same SMA as built-in MovingAverage on a 1Day chart (with the same lengths)
Sessions H/L [eFe]An indicator for visualizing Session Highs/Lows and Daily/Weekly/Monthly Open/High/Low levels. This tool is designed to help traders identify key support and resistance levels formed during specific trading sessions and higher timeframes.
## Features
### 1. Session Highs & Lows
Automatically tracks and draws the High and Low prices for user-defined trading sessions.
* **Sessions Supported:**
* Asia
* London
* NY AM
* NY Lunch
* NY PM
* **Visuals:**
* Draws a box covering the session range (High to Low).
* Extends lines from the Session High and Low into the future.
* **Auto-Cutoff:** Lines automatically stop extending when price breaks them (Price >= High Line or Price <= Low Line).
* Optional text labels for Highs and Lows.
### 2. DWM (Day - Week - Month) Levels
Tracks and displays Open, High, and Low levels for higher timeframes.
* **Levels:**
* **Open:** Daily, Weekly, Monthly Open prices.
* **High/Low:** Previous Day/Week/Month Highs and Lows.
* **Visuals:**
* Line extensions for Open prices until broken or timed out.
* Line extensions for Previous High/Low until price touches them.
Anchored VWAP PercentageINDICATOR: ANCHORED VWAP PERCENTAGE (AVWAP)
1. Overview
The Anchored VWAP Percentage (AVWAP) is a quantitative momentum and mean-reversion tool. It measures the percentage distance between the current price and a Volume Weighted Average Price (VWAP) that resets automatically based on specific time cycles. It allows traders to identify overextended market conditions relative to institutional value.
---
2. Core Logic & Calculation
The script tracks the relationship between price and volume starting from a specific Anchor Point .
* Volume-Weighted Foundation: Unlike simple moving averages, this indicator uses the VWAP formula: sum(Volume * Price) / sum(Volume) .
* Automatic Anchoring: The starting point (Anchor) resets automatically depending on the chart timeframe (e.g., resets weekly on a 15m chart, or yearly on a Daily chart).
* Percentage Deviation: It calculates the precise gap between the price and the VWAP, plotted as an oscillator: ((Price - VWAP) / VWAP) * 100 .
---
3. Adaptive Intelligence (Multi-Asset & Multi-TF)
The AVWAP is built with an internal database of 85th Percentile (P85) volatility thresholds. It recognizes that different assets have different "stretching" limits:
1. Asset-Specific Calibration: It includes optimized data for Bitcoin, Ethereum, Altcoins, Forex, and Indices .
2. Dynamic Timeframe Mapping: The anchor period and the exhaustion thresholds adjust automatically. For example:
* Intraday (1m-5m): Anchors to an 8-hour (480 min) cycle.
* Mid-Term (15m-60m): Anchors to a Weekly (W) cycle.
* Swing (Daily): Anchors to a Yearly (12M) cycle.
---
4. Visual Anatomy
The indicator is designed for high-speed decision-making:
* The Histogram:
* Green: Price is trading above the VWAP (Bullish premium).
* Red: Price is trading below the VWAP (Bearish discount).
* P85 Threshold Lines:
* These lines represent the 85th percentile of historical deviations . Historically, the price stays within these boundaries 85% of the time.
* Background Highlighting: When the histogram crosses the P85 line, the background glows, signaling a Statistical Exhaustion Zone where a retracement to the mean is highly probable.
---
5. How to Trade with AVWAP
* Mean Reversion: When the histogram reaches the P85 Zone , the price is "statistically overextended." This is a prime area to look for reversals or to take profits on existing trends.
* Trend Strength: If the histogram stays near the Zero Line while the price moves, the trend is supported by healthy volume.
* Value Area: The Zero Line represents the Fair Value . Buying near the Zero Line during a bullish histogram (Green) offers a high-probability entry with low risk.
---
6. Technical Parameters
* Asset Selection: A dropdown to switch between Crypto, Forex, and Indices.
* Color Customization: User-defined colors for bullish and bearish sentiment.
* Precision Control: 4-decimal precision for accurate tracking of thin-margin assets like Forex.
ADR/ATR/EMA % FILTERADR%
ATR%
Daily EMA 5 % Distance
Daily EMA 10% Distance
2 Hour EMA 20% Distance
20-Day price control
20-Week price control
XU100 Index 5/20 control on 4-hour
Auto Session Fib (Daily / Weekly)Session-Anchored Fibonacci (RTH Only)
Automatically tracks the Regular Trading Hours session (09:30–16:00).
Fibonacci levels are built only from session high and low, not overnight noise.
Levels dynamically update throughout the session and anchor precisely at 09:30.
Session levels plotted:
High / Low
50% retracement
61.8%, 78.6%, 88.6% (bullish and bearish interpretations)
These levels are intended for intraday execution, not bias.
2️⃣ Previous Week Fibonacci (Market Context)
Displays previous week High, Low, and Fibonacci retracements.
Lines are confined strictly to the prior week (no overlap into the current week).
Levels are shown in a faint gray to distinguish context from execution.
Each key fib level includes descriptive labels, not just numbers:
61.8% → Golden Zone anchor
78.6% → Deep pullback / last defense
88.6% → Trend failure / trap zone
These are decision-framing levels, designed to help identify where trends either hold or fail.
3️⃣ Previous Day Extension Zones (Expansion Targets)
Calculates previous day range and projects:
+1.618 / +1.786
−1.618 / −1.786
Draws filled zones (no borders) between:
1.618 ↔ 1.786
−1.618 ↔ −1.786
Boxes extend only across the current RTH session.
These zones represent expansion / exhaustion areas, not reversal signals by themselves.
4️⃣ RSI Turn Signals (Clean, Non-Repainting)
Uses a standard RSI, with:
Adjustable length
Adjustable overbought / oversold levels
Optional independent RSI timeframe (can differ from chart TF)
Signals trigger only on a turn, not while RSI remains extreme:
Buy: RSI crosses up through oversold
Sell: RSI crosses down through overbought
This indicator is built to answer three questions:
Where am I relative to important structure?
Is price extended or mean-reverting?
Is there a confirmed momentum turn?
HaP Williams %R Pro+This indicator combines the classic Williams %R (Percent Range) oscillator with multi-timeframe (MTF) analysis, allowing you to visualize the general market direction on a single chart. Thanks to its advanced dashboard feature, you can instantly monitor overbought/oversold conditions across all periods, ranging from the 1-minute chart to the 1-month chart.
With the AVG F feature added to the table, short-term price movements and momentum changes (specifically for Scalping) can be detected much faster.
🚀 Key Features
Multi-Timeframe (MTF) Support: Simultaneously calculates Williams %R values for 1m, 5m, 15m, 30m, 1h, 2h, 4h, Daily, Weekly, and Monthly periods.
Smart Dashboard: The table located in the corner of the screen displays values and color codes for all timeframes.
AVG S (Slow Average): This is the average of 5m, 15m, 30m, and 1h data. It indicates the general trend direction.
AVG F (Fast Average) : This is the average of 1m, 5m, and 15m data. It is used for instant momentum and scalping entries.
Signal Smoothing: Williams %R data is smoothed with a Simple Moving Average (SMA) to reduce market noise.
Dynamic Coloring: Colors on the dashboard and chart automatically change according to the strength of the trend.
🎨 Color Codes and Meanings
The dashboard and chart lines are colored according to the following logic:
🟢 Bright Green (Lime): If the value is above -20. This is the "Overbought" zone, but it indicates a strong Bullish trend. Momentum is very high.
🌿 Dark Green: If the value is between -20 and -50. The market is in the positive zone; the upward tendency continues.
🔴 Red: If the value is between -50 and -80. The market is in the negative zone; the downward tendency dominates.
🛑 Bright Red: If the value is below -80. This is the "Oversold" zone. Momentum is very low, and the Bearish trend is strong.
💡 How to Use? (Strategy Suggestions)
General Trend Tracking: Look at the AVG S (Slow Average) column in the dashboard. If it is green, the general direction is up; if red, it is down.
Scalp Trades: The AVG F (Fast Average) column is ideal for catching short-term reversals. Entry reliability increases when the AVG F color aligns with AVG S.
Crossovers: Crossovers between the Fast Average (Red Line) and Slow Average (Black Line) on the chart can signal potential trend changes.
Dashboard Harmony: If all boxes (or the vast majority) in the dashboard are the same color (e.g., all green), it indicates a very strong trend in that direction. You should avoid opening positions in the opposite direction.
⚙️ Settings
Williams %R Period: Default is 14; you can change it according to your strategy.
Dashboard Position: You can move the dashboard to the top-right, bottom-right, or bottom-left corner of the screen.
Show Lines: If you want to prevent chart clutter, you can toggle off the lines and use only the dashboard.
Disclaimer: This indicator is a support tool and does not contain definitive buy/sell signals. You should make your investment decisions based on your own analysis and risk management.
Nexus Momentum Flow [JOAT]
Nexus Momentum Flow - ADX-Based Trend Strength Analysis
Introduction and Purpose
Nexus Momentum Flow is an open-source oscillator indicator that combines the ADX (Average Directional Index) with directional movement indicators (+DI/-DI) to create a comprehensive trend strength and direction analysis tool. The core problem this indicator solves is that ADX alone tells you trend strength but not direction, while +DI/-DI alone tells you direction but not strength. Traders need both pieces of information together.
This indicator addresses that by combining ADX strength classification with directional bias into a single confluence score, making it easy to identify when strong trends exist and which direction they favor.
Why These Components Work Together
1. ADX (Average Directional Index) - Measures trend strength regardless of direction. Values above 25 indicate trending; below 20 indicate ranging.
2. +DI (Positive Directional Indicator) - Measures upward price movement strength.
3. -DI (Negative Directional Indicator) - Measures downward price movement strength.
4. Confluence Score - Combines ADX strength with DI bias to create a single actionable metric.
The combination works because:
ADX filters out ranging markets where DI crossovers produce whipsaws
DI relationship provides direction when ADX confirms trend
Confluence score simplifies the analysis into one number
How the Calculation Works
float directionBias = diPlus - diMinus
float confluenceScore = (adx / 100) * directionBias
The confluence score is positive when +DI > -DI (bullish) and negative when -DI > +DI (bearish), with magnitude scaled by ADX strength.
Trend State Classification
EXTREME - ADX > 50 (very strong trend)
STRONG - ADX 35-50 (strong trend)
TRENDING - ADX 25-35 (moderate trend)
RANGING - ADX < 25 (no clear trend)
Dashboard Information
Status - Current trend state (EXTREME/STRONG/TRENDING/RANGING)
Direction - BULLISH or BEARISH based on DI relationship
ADX - Current ADX value
DI Bias - Difference between +DI and -DI
Confluence - Combined score with directional context
How to Use This Indicator
For Trend Following:
1. Wait for ADX to show TRENDING or higher
2. Check direction matches your trade bias
3. Enter on pullbacks when confluence remains positive/negative
4. Exit when ADX drops to RANGING
For Avoiding Whipsaws:
1. Do not trade DI crossovers when ADX shows RANGING
2. Only trust directional signals when ADX confirms trend
3. Use RANGING periods for mean-reversion strategies instead
For Trend Exhaustion:
1. Watch for EXTREME ADX readings
2. Extreme trends often precede reversals
3. Consider taking profits when ADX reaches extreme levels
Input Parameters
ADX Length (14) - Period for ADX calculation
DI Length (14) - Period for directional indicators
ADX Smoothing (14) - Smoothing period for ADX
Trend Threshold (25) - ADX level for trend confirmation
Strong Threshold (35) - ADX level for strong trend
Extreme Threshold (50) - ADX level for extreme trend
Timeframe Recommendations
Daily/4H: Best for swing trading trend analysis
1H: Good for intraday trend following
15m: More signals but requires faster reaction
Limitations
ADX is a lagging indicator - trends are confirmed after they start
DI crossovers can whipsaw even with ADX filter
Works best in markets that trend clearly
May miss early trend entries due to confirmation requirement
Open-Source and Disclaimer
This script is published as open-source under the Mozilla Public License 2.0 for educational purposes.
This indicator does not constitute financial advice. Trend analysis does not guarantee profitable trades. Always use proper risk management.
- Made with passion by officialjackofalltrades
Pullback Master CareCA clean, reliable pullback trading indicator that identifies optimal entry points during trend corrections. It combines daily trend direction with intraday momentum, volume patterns, and RSI oversold conditions to signal high-probability buy opportunities when price pulls back in an uptrend.
Perfect for swing traders looking to enter with the trend after temporary sell-offs, with built-in confirmation filters to avoid false signals.
SMA 2 & SMA 12 configurables + alertesEnjoy to use this indicator used in Powertrade community.
Thanks to Patrick, for his community.
It's a powerfull signal for sell and buy.
When the SMA 2 days goes above the SMA 12 days, it's a buy signal.
When the SMA 2 days goes below the SMA 12 days, it's a sell signal.
I recommand too, the use of : jeremiefranklin1 indicator based on 2 DEMA 20 + Choch patterns by BigBeluga + daily Candle by Natantia.
This combination will give you a really powerfull trading setup to earn lots of money with different trading assets.
Have fun.
ZLT - Date and Time MarkerPine Script v5 indicator called “DateTime Marker” that overlays on the chart and marks bars whose timestamp matches a user-defined schedule. When a bar “matches,” it can draw:
a vertical line through the bar,
a label with a time/date string, and
a triangle marker below the bar (always plotted on matches).
What you can configure
Marker Type (the matching rule)
You choose one of five modes:
Every Minute
Inputs: everyNMinutes (default 15), minuteOffset (default 0)
Match condition: minute % everyNMinutes == minuteOffset
Example with defaults: marks bars at :00, :15, :30, :45 each hour.
Hourly
Inputs: everyNHours (default 4), hourlyMinute (default 0)
Match condition: hour % everyNHours == 0 AND minute == hourlyMinute
Example with defaults: marks bars at 00:00, 04:00, 08:00, 12:00, 16:00, 20:00 (at minute 00).
Daily Time
Inputs: dailyHour (default 10), dailyMinute (default 0)
Match condition: hour == dailyHour AND minute == dailyMinute
Example with defaults: marks 10:00 every day.
Weekly Day & Time
Inputs: weekDay (default Tuesday), weeklyHour (default 16), weeklyMinute (default 0)
It converts the weekday name to Pine’s dayofweek number via getDayNumber().
Match condition: dayofweek == targetDay AND hour == weeklyHour AND minute == weeklyMinute
Example with defaults: marks Tuesday 16:00.
Monthly Date & Time
Inputs: monthlyDay (default 2), monthlyHour (default 23), monthlyMinute (default 0)
Match condition: dayofmonth == monthlyDay AND hour == monthlyHour AND minute == monthlyMinute
Example with defaults: marks the 2nd day of each month at 23:00.
Visual settings
showLine: whether to draw the vertical line.
lineStyle: Solid/Dashed/Dotted (mapped to Pine line styles by getLineStyle()).
lineColor, lineWidth: styling for the line (width is rounded to an integer because Pine line width is integer).
showLabel: whether to draw a label.
labelColor: background color of the label (text is forced white).
What happens when a bar matches
When isMatch becomes true on a bar:
Vertical line: line.new() at that bar’s bar_index, from low to high, extended extend.both (so it spans the full chart vertically).
Label: label.new() at the bar’s high, with mode-specific text:
Minute/Hourly/Daily: "HH:mm"
Weekly: "Tuesday HH:mm" (or whatever day selected)
Monthly: "Day 2 - HH:mm" (or chosen day)
Triangle marker: plotshape() draws a triangle up below the bar on every match (this happens regardless of showLine / showLabel).
Important practical implications
This uses the bar’s exchange/chart time (TradingView’s time, hour, minute, etc.), so results depend on the symbol/session and chart timezone settings.
On timeframes coarser than 1 minute, “Every Minute” still checks only the bar’s timestamp minute value; it won’t mark intra-bar minutes that don’t exist as separate bars.
Because it can create many objects (lines/labels), it sets max_labels_count=500. Lines are not capped here, so very dense marking can still clutter the chart.
If you tell me your intended use (e.g., “mark NY open,” “mark every 15m candle close,” “mark macro events weekly”), I can point out whether the current matching logic fits that precisely or needs adjustments (sessions, timezones, avoiding duplicates, limiting lines, etc.).
ADR % RangesThis indicator is designed to visually represent percentage lines from the open of the day. The % amount is determined by X amount of the last days to create an average...or Average Daily Range (ADR).
1. ADR Percentage Lines: The core function of the script is to apply lines to the chart that represent specific percentage changes from the daily open. It first calculates the average over X amount of days and then displays two lines that are 1/3rd of that average. One line goes above the other line goes below. The other two lines are the full "range" of the average. These lines can act as boundaries or targets to know how an asset has moved recently. *Past performance is not indicative of current or future results.
The calculation for ADR is:
Step 1. Calculate Today's Range = DailyHigh - DailyLow
Step 2. Store this average after the day has completed
Step 3. Sum all day's ranges
Step 4. Divide by total number of days
Step 5. Draw on chart
2. Customizable Inputs: Users have the flexibility to customize the script through various inputs. This includes the option to display lines only for the current trading day (`todayonly`), and to select which lines are displayed. The user can also opt to show a table the displays the total range of previous days and the average range of those previous days.
3. No Secondary Timeframe: The ADR is computed based on whatever timeframe the chart is and does not reference secondary periods. Therefore the script cannot be used on charts greater than daily.
This script is can be used by all traders for any market. The trader might have to adjust the "X" number of days back to compute a historical average. Maybe they only want to know the average over the past week (5 days) or maybe the past month (20 days).
Humble Student OB/OS Trifecta indicatorAfter reading Cam Hui's blog post about his "Trifecta" bottom spotting model I thought I'd try my hand at scripting it as an indicator. The results are pretty close to what he describes. Though the data TradingView feeds me doesn't seem to be identical to what he's using on StockCharts.com the results are close enough that I will call the effort a success worth publishing.
MTF 20 SMA Table - DXY**MTF 20 SMA Table - Multi-Timeframe Trend Analysis Dashboard**
**Overview:**
This indicator provides a comprehensive multi-timeframe analysis dashboard that displays the relationship between price and the 20-period Simple Moving Average (SMA) across four key timeframes: 15-minute, 1-hour, 4-hour, and Daily. It's designed to help traders quickly identify trend alignment and potential trading opportunities across multiple timeframes at a glance. It's definitely not perfect but has helped me speed up my backtesting efforts as it's worked well for me eliminating flipping back and forth between timeframes excpet when I have confluence on the table, then I check the HTF.
**How It Works:**
The indicator creates a table overlay on your chart showing three critical metrics for each timeframe:
1. **Price vs SMA (Row 1):** Shows whether price is currently above (bullish) or below (bearish) the 20 SMA
- Green = Price Above SMA
- Red = Price Below SMA
2. **SMA Direction (Row 2):** Indicates the trend direction of the SMA itself over a lookback period
- Green (↗ Rising) = Uptrend
- Red (↘ Falling) = Downtrend
- Gray (→ Flat) = Ranging/Consolidation
3. **Strength (Row 3):** Displays the distance between current price and the SMA in pips
- Purple background = Strong move (>50 pips away)
- Orange background = Moderate move (20-50 pips)
- Gray background = Weak/consolidating (<20 pips)
- Text color: Green for positive distance, Red for negative
**Key Features:**
- **Customizable Table Position:** Place the table anywhere on your chart (9 position options)
- **Adjustable SMA Lengths:** Modify the SMA period for each timeframe independently (default: 20)
- **Direction Lookback Settings:** Fine-tune how far back the indicator looks to determine SMA direction for each timeframe
- **Flat Threshold:** Set the pip threshold for determining when an SMA is "flat" vs trending (default: 5 pips)
- **DXY Optimized:** Calculations are calibrated for the US Dollar Index (1 pip = 0.01)
**Best Use Cases:**
1. **Trend Alignment:** Identify when multiple timeframes align in the same direction for higher probability trades
2. **Divergence Spotting:** Detect when lower timeframes diverge from higher timeframes (potential reversals)
3. **Entry Timing:** Use lower timeframe signals while higher timeframes confirm overall trend
4. **Strength Assessment:** Gauge how extended price is from the mean (SMA) to avoid overextended entries
**Settings Guide:**
- **SMA Settings Group:** Adjust the SMA period for each timeframe (15M, 1H, 4H, Daily)
- **SMA Direction Group:** Control lookback periods to determine trend direction
- 15M: Default 5 candles
- 1H: Default 10 candles
- 4H: Default 15 candles
- Daily: Default 20 candles
- **Flat Threshold:** Set sensitivity for "flat" detection (lower = more sensitive to ranging markets)
**Trading Strategy Examples:**
1. **Trend Following:** Look for all timeframes showing the same direction (all green or all red)
2. **Pullback Trading:** When Daily/4H are green but 15M/1H show red, wait for lower timeframes to flip green for entry
3. **Ranging Markets:** When multiple SMAs show "flat", consider range-bound strategies
**Important Notes:**
- This is a reference tool only, not a standalone trading system
- Always use proper risk management and combine with other analysis methods
- Best suited for trending instruments like indices and major forex pairs
- Calculations are optimized for DXY but can be used on other instruments (pip calculations may need adjustment)
**Credits:**
Feel free to modify and improve this code! Suggestions for enhancements are welcome in the comments.
---
**Installation Instructions:**
1. Add the indicator to your TradingView chart
2. Adjust the table position via settings to avoid overlap with price action
3. Customize SMA lengths and lookback periods to match your trading style
4. Monitor the table for timeframe alignment and trend confirmation
---
This indicator is published as open source for the community to learn from and improve upon. Happy trading! 📈
BTC Backwardation SearcherThis Pine Script code is a custom indicator named "BTC Backwardation Searcher" designed for the TradingView platform. The indicator aims to identify and visualize the price difference between two Bitcoin futures contracts: CME:BTC1! and CME:BTC2!.
Here's a breakdown of the code:
1. The script fetches the daily close prices of CME:BTC1! and CME:BTC2! using the security() function.
2. It calculates the percentage price difference between the two contracts using the formula: (btc1Price - btc2Price) / btc2Price * 100.
3. The script also calculates the price difference for the previous two days (2 days ago and 3 days ago) using the same formula.
4. Two conditions are defined:
(1) dailyGreenCondition: If the price difference is greater than or equal to 0.3% for three
consecutive days, including the current day and the previous two days.
(2) dailyRedCondition(commented): If the price difference is less than or equal to -1% for three consecutive days, including the current day and the previous two days.
(I commented it out because I don't think it's useful.)
5. The plotshape() function is used to display green triangles on the chart when the dailyGreenCondition is met, and red triangles when the dailyRedCondition is met. These triangles are displayed on the daily, weekly, and monthly timeframes.
The purpose of this indicator is to help traders identify potential trading opportunities based on the price difference between the two Bitcoin futures contracts. The green triangles suggest a bullish scenario where CME:BTC1! is significantly higher than CME:BTC2!, while the red triangles indicate a bearish scenario where CME:BTC2! is significantly lower than CME:BTC1!.
However, it's important to note that this indicator should be used in conjunction with other technical analysis tools and fundamental analysis. Traders should also consider their risk tolerance, investment goals, and market conditions before making any trading decisions based on this indicator.
ES Multi-Timeframe SMC Entry SystemOverviewThis is a comprehensive Smart Money Concepts (SMC) trading strategy for ES1! (E-mini S&P 500) futures that provides simultaneous buy and sell signals across three timeframes: Daily, Weekly, and Monthly. It incorporates your complete entry checklists, confluence scoring system, and automated risk management.Core Features1. Multi-Timeframe Signal Generation
Daily Signals (D) - For intraday/swing trades (1-3 day holds)
Weekly Signals (W) - For swing trades (3-10 day holds)
Monthly Signals (M) - For position trades (weeks to months)
All three timeframes can trigger simultaneously (pyramiding enabled)
2. Smart Money Concepts ImplementationOrder Blocks (OB)
Automatically detects bullish and bearish order blocks
Bullish OB = Down candle before strong impulse up
Bearish OB = Up candle before strong impulse down
Validates freshness (< 10 bars = higher quality)
Visual boxes displayed on chart
Fair Value Gaps (FVG)
Identifies 3-candle imbalance patterns
Bullish FVG = Gap between high and current low
Bearish FVG = Gap between low and current high
Tracks unfilled gaps as targets/entry zones
Auto-removes when filled
Premium/Discount Zones
Calculates 50-period swing range
Premium = Upper 50% (short from here)
Discount = Lower 50% (long from here)
Deep zones (<30% or >70%) for higher quality setups
Visual shading: Red = Premium, Green = Discount
Liquidity Sweeps
Sell-Side Sweep (SSL) = False break below lows → reversal up
Buy-Side Sweep (BSL) = False break above highs → reversal down
Marked with yellow labels on chart
Valid for 10 bars after occurrence
Break of Structure (BOS)
Identifies when price breaks recent swing high/low
Confirms trend continuation
Marked with small circles on chart
3. Confluence Scoring SystemEach timeframe has a 10-point scoring system based on your checklist requirements:Daily Score (10 points max)
HTF Trend Alignment (2 pts) - 4H and Daily EMAs aligned
SMC Structure (2 pts) - OB in correct zone with HTF bias
Liquidity Sweep (1 pt) - Recent SSL/BSL occurred
Volume Confirmation (1 pt) - Volume > 1.2x 20-period average
Optimal Time (1 pt) - 9:30-12 PM or 2-4 PM ET (avoids lunch)
Risk-Reward >2:1 (1 pt) - Built into exit strategy
Clean Price Action (1 pt) - BOS occurred
FVG Present (1 pt) - Near unfilled fair value gap
Minimum Required: 6/10 (adjustable)Weekly Score (10 points max)
Weekly/Monthly Alignment (2 pts) - W and M EMAs aligned
Daily/Weekly Alignment (2 pts) - D and W trends match
Premium/Discount Correct (2 pts) - Deep zone + trend alignment
Major Liquidity Event (1 pt) - SSL/BSL sweep
Order Block Present (1 pt) - Valid OB detected
Risk-Reward >3:1 (1 pt) - Built into exit
Fresh Order Block (1 pt) - OB < 10 bars old
Minimum Required: 7/10 (adjustable)Monthly Score (10 points max)
Monthly/Weekly Alignment (2 pts) - M and W trends match
Weekly OB in Monthly Zone (2 pts) - OB in deep discount/premium
Major Liquidity Sweep (2 pts) - Significant SSL/BSL
Strong Trend Alignment (2 pts) - D, W, M all aligned
Risk-Reward >4:1 (1 pt) - Built into exit
Extreme Zone (1 pt) - Price <20% or >80% of range
Minimum Required: 8/10 (adjustable)4. Entry ConditionsDaily Long Entry
✅ Daily score ≥ 6/10
✅ 4H trend bullish (price > EMAs)
✅ Price in discount zone
✅ Bullish OB OR SSL sweep OR near bullish FVG
✅ NOT during avoid times (lunch/first 5 min)Daily Short Entry
✅ Daily score ≥ 6/10
✅ 4H trend bearish
✅ Price in premium zone
✅ Bearish OB OR BSL sweep OR near bearish FVG
✅ NOT during avoid timesWeekly Long Entry
✅ Weekly score ≥ 7/10
✅ Weekly trend bullish
✅ Daily trend bullish
✅ Price in discount
✅ Bullish OB OR SSL sweepWeekly Short Entry
✅ Weekly score ≥ 7/10
✅ Weekly trend bearish
✅ Daily trend bearish
✅ Price in premium
✅ Bearish OB OR BSL sweepMonthly Long Entry
✅ Monthly score ≥ 8/10
✅ Monthly trend bullish
✅ Weekly trend bullish
✅ Price in DEEP discount (<30%)
✅ Bullish order block presentMonthly Short Entry
✅ Monthly score ≥ 8/10
✅ Monthly trend bearish
✅ Weekly trend bearish
✅ Price in DEEP premium (>70%)
✅ Bearish order block present5. Automated Risk ManagementPosition Sizing (Per Entry)
Daily: 1.0% account risk per trade
Weekly: 0.75% account risk per trade
Monthly: 0.5% account risk per trade
Formula:
Contracts = (Account Equity × Risk%) ÷ (Stop Points × $50)
Minimum = 1 contractStop Losses
Daily: 12 points ($600 per contract)
Weekly: 40 points ($2,000 per contract)
Monthly: 100 points ($5,000 per contract)
Profit Targets (Risk:Reward)
Daily: 2:1 = 24 points ($1,200 profit)
Weekly: 3:1 = 120 points ($6,000 profit)
Monthly: 4:1 = 400 points ($20,000 profit)
Example with $50,000 AccountDaily Trade:
Risk = $500 (1% of $50k)
Stop = 12 points × $50 = $600
Contracts = $500 ÷ $600 = 0.83 → 1 contract
Target = 24 points = $1,200 profit
Weekly Trade:
Risk = $375 (0.75% of $50k)
Stop = 40 points × $50 = $2,000
Contracts = $375 ÷ $2,000 = 0.18 → 1 contract
Target = 120 points = $6,000 profit
Monthly Trade:
Risk = $250 (0.5% of $50k)
Stop = 100 points × $50 = $5,000
Contracts = $250 ÷ $5,000 = 0.05 → 1 contract
Target = 400 points = $20,000 profit
6. Visual Elements on ChartKey Levels
Previous Daily High/Low - Red/Green solid lines
Previous Weekly High/Low - Red/Green circles
Previous Monthly High/Low - Red/Green crosses
Equilibrium Line - White dotted line (50% of range)
Zones
Premium Zone - Light red shading (upper 50%)
Discount Zone - Light green shading (lower 50%)
SMC Markings
Bullish Order Blocks - Green boxes with "Bull OB" label
Bearish Order Blocks - Red boxes with "Bear OB" label
Bullish FVGs - Green boxes with "FVG↑"
Bearish FVGs - Red boxes with "FVG↓"
Liquidity Sweeps - Yellow "SSL" (down) or "BSL" (up) labels
Break of Structure - Small lime/red circles
Entry Signals
Daily Long - Small lime triangle ▲ with "D" below price
Daily Short - Small red triangle ▼ with "D" above price
Weekly Long - Medium green triangle ▲ with "W" below price
Weekly Short - Medium maroon triangle ▼ with "W" above price
Monthly Long - Large aqua triangle ▲ with "M" below price
Monthly Short - Large fuchsia triangle ▼ with "M" above price
7. Information TablesConfluence Score Table (Top Right)
┌──────────┬────────┬────────┬────────┐
│ TF │ SCORE │ STATUS │ SIGNAL │
├──────────┼────────┼────────┼────────┤
│ 📊 DAILY │ 7/10 │ ✓ PASS │ 🔼 │
│ 📈 WEEKLY│ 6/10 │ ✗ WAIT │ ━ │
│ 🌙 MONTH │ 9/10 │ ✓ PASS │ 🔽 │
├──────────┴────────┴────────┴────────┤
│ P&L: $2,450 │
└─────────────────────────────────────┘
Green scores = Pass (meets minimum threshold)
Orange/Red scores = Fail (wait for better setup)
🔼 = Long signal active
🔽 = Short signal active
━ = No signal
Entry Checklist Table (Bottom Right)
┌──────────────┬───┐
│ CHECKLIST │ ✓ │
├──────────────┼───┤
│ ━ DAILY ━ │ │
│ HTF Trend │ ✓ │
│ Zone │ ✓ │
│ OB │ ✗ │
│ Liq Sweep │ ✓ │
│ Volume │ ✓ │
│ ━ WEEKLY ━ │ │
│ W/M Align │ ✓ │
│ Deep Zone │ ✗ │
│ ━ MONTHLY ━ │ │
│ M/W/D Align │ ✓ │
│ Zone: Discount│ │
└──────────────┴───┘
Green ✓ = Condition met
Red ✗ = Condition not met
Real-time updates as market conditions change
8. Alert SystemIndividual Alerts:
"Daily Long" - Triggers when daily long setup appears
"Daily Short" - Triggers when daily short setup appears
"Weekly Long" - Triggers when weekly long setup appears
"Weekly Short" - Triggers when weekly short setup appears
"Monthly Long" - Triggers when monthly long setup appears
"Monthly Short" - Triggers when monthly short setup appears
Combined Alerts:
"Any Long Signal" - Catches any bullish opportunity (D/W/M)
"Any Short Signal" - Catches any bearish opportunity (D/W/M)
Alert Messages Include:
🔼/🔽 Direction indicator
Timeframe (DAILY/WEEKLY/MONTHLY)
Current confluence score
HTF Current/Average RangeThe "HTF(Higher Timeframe) Current/Average Range" indicator calculates and displays the current and average price ranges across multiple timeframes, including daily, weekly, monthly, 4 hour, and user-defined custom timeframes.
Users can customize the lookback period, table size, timeframe, and font color; with the indicator efficiently updating on the final bar to optimize performance.
When the current range surpasses the average range for a given timeframe, the corresponding table cell is highlighted in green, indicating potential maximum price expansion and signaling the possibility of an impending retracement or consolidation.
For day trading strategies, the daily average range can serve as a guide, allowing traders to hold positions until the current daily range approaches or meets the average range, at which point exiting the trade may be considered.
For scalping strategies, the 15min and 5min average range can be utilized to determine optimal holding periods for fast trades.
Other strategies:
Intraday Trading - 1h and 4h Average Range
Swing Trading - Monthly Average Range
Short-term Trading - Weekly Average Range
Also using these statistics in accordance with Power 3 ICT concepts, will assist in holding trades to their statistical average range of the chosen HTF candle.
CODE
The core functionality lies in the data retrieval and table population sections.
The request.security function (e.g., = request.security(syminfo.tickerid, "D", , lookahead = barmerge.lookahead_off)) retrieves high and low prices from specified timeframes without lookahead bias, ensuring accurate historical data.
These values are used to compute current ranges and average ranges (ta.sma(high - low, avgLength)), which are then displayed in a dynamically generated table starting at (if barstate.islast) using table.new, with conditional green highlighting when the current range is greater than average range, providing a clear visual cue for volatility analysis.
HMA & D1 crossover FX (Study)Can work on other Forex pairs if change settings: Period
This example tuned for AUDUSD (FX Version)
Enter new order on HMA ( Hull Moving Average ) and D1 ( Daily Candle) crossovers, Exit orders as basket when profit = Your Target Profit
This study version built for users of Alerts. Crossover of HMA and DailyCandle1 (and/or DailyCandle1 cross DailyCandle2) (also possible Price cross HMA)






















