OPEN-SOURCE SCRIPT
מעודכן

Daily Trade Plan Generator [AGPro Series]

6 304
Daily Trade Plan Generator [AGPro Series]

Daily Trade Plan Generator — complete morning briefing tool that generates a structured, rules-based trade plan for every new trading day. Combines key levels, multi-timeframe bias, projected volatility range, and adaptive Plan A/B/C playbooks into one premium dashboard.

🔷 OVERVIEW

Most traders start their day scattered — flipping through charts, trying to remember yesterday's highs and lows, guessing where the market might move. Daily Trade Plan Generator replaces that chaos with a single structured briefing. Every new trading day (either at UTC midnight for crypto or at a configurable exchange session open), the script automatically generates a complete plan: where the key levels are, which direction has the stronger multi-timeframe bias, how wide the day is likely to trade, and what the Plan A, Plan B, and Plan C playbooks look like. It is the first tool to open every morning — and it is self-updating, so you never have to reset it.

This is not a signal generator and not a strategy. It is a briefing tool, designed for traders who want to start every session with the same structured preparation a professional desk would do — without spending 30 minutes on it manually.

🎯 UNIQUE EDGE

What separates this script from generic level indicators and daily-high-low plotters:

• All-in-one daily briefing — levels, bias, volatility, and Plan A/B/C in one dashboard, not four separate indicators cluttering the chart.
• Multi-timeframe bias score (0 to 100) blending 1H, 4H, Daily, and Weekly EMA structure with three configurable weighting modes (Fast, Balanced, Conservative) so the bias matches your trading style.
• Asset-class-aware round numbers — the script auto-detects price magnitude and picks sensible round-number intervals (1000 for BTC-scale assets, 0.01 for forex majors, and so on) without manual setup.
• Projected daily range as a visual zone — ATR-based expected high and low rendered either as a semi-transparent rectangle, dashed lines, or both, giving you an immediate read on where price is likely to operate.
• Plan A / Plan B / Plan C structure (user-configurable 1 to 3) — deliberate "Plan" terminology to avoid confusion with pivot S/R notation. Plan language uses historical-pattern framing with no forecasting claims.
• Two refresh anchors plus a "both visible" option — crypto traders get UTC midnight, equities/futures traders get configurable session open, swing traders can see both markers.
• Timeframe-adaptive behavior — on weekly and higher timeframes, PDH/PDL automatically hide (since "previous day" is not meaningful there), and Plan A/B references shift to PWH/PWL for consistency.
• Smart label collision avoidance — PROJ HI/LO, PDH/PDL, and PWH/PWL labels intelligently reposition when too close together, keeping every chart readable at any scale.
• Volatility regime classification (Low / Normal / High) with a context-aware risk note that adapts to market conditions.

🧩 METHODOLOGY

LEVELS. Previous Day High/Low and Previous Week High/Low are pulled via higher-timeframe requests and rendered as persistent lines extending from today's session open to the right. The nearest round number is drawn as a single dotted line on the chart; the full list of nearby round numbers is shown in the dashboard panel to keep the chart clean.

BIAS SCORE. For each timeframe (1H, 4H, 1D, 1W), three components are evaluated: fast EMA versus slow EMA relationship, close versus fast EMA position, and fast EMA slope direction. Each component contributes plus or minus one, averaged to a per-timeframe score between -1 and +1. The four timeframe scores are then combined using the selected weighting mode and normalized to a 0-100 scale. Scores above 65 are labeled Bull, below 35 Bear, and in between Neutral.

VOLATILITY. Daily ATR over the configurable length (default 14) determines the expected range. The range is centered on today's session open and expanded by the Range Multiplier input. ATR as a percentage of open price classifies the regime: below 1% is Low, above 4% is High, in between is Normal.

PLANS. The script composes Plan A (primary, aligned with bias), optionally Plan B (alternative, opposite-side rejection path), and optionally Plan C (range / mean-reversion, activated when volatility is low or bias is neutral). Plan references adapt automatically to chart timeframe — intraday and daily charts use PDH/PDL, weekly and higher charts use PWH/PWL. The language is deliberately conditional and references historical patterns rather than predicting future prices.

🔔 SIGNALS & ALERTS

The script includes five built-in alert conditions:

• New Daily Plan Generated — fires when the daily refresh anchor triggers.
• Price Broke PDH — crossover above Previous Day High.
• Price Broke PDL — crossunder below Previous Day Low.
• Price Exceeded Projected High — crossover above ATR-projected high (volatility expansion).
• Price Exceeded Projected Low — crossunder below ATR-projected low (volatility expansion).

Each alert includes the ticker and relevant price in the message payload, ready to route into any alert handler.

⚙️ KEY INPUTS

• Daily Refresh Anchor — UTC Midnight, Exchange Session, or Both Visible.
• Exchange Session Open Hour — 0 to 23, used when Exchange or Both is selected.
• Key Levels toggles — PDH/PDL, PWH/PWL, Round Numbers individually toggleable.
• Round Numbers in panel — 1 to 5 levels above and below the current price.
• Bias Calculation Mode — Fast (HTF-weighted), Balanced, or Conservative (MTF-weighted).
• EMA Fast / Slow periods — defaults 20 and 50.
• ATR Length and Range Multiplier — control the width of the projected daily range.
• Expected Range Visualization — Zone (Box), Dashed Lines, or Both.
• Number of Plans — A, A+B, or A+B+C.
• Panel Location — six corner/middle positions.
• Panel and Label font sizes — Tiny through Huge, default Normal.
• Panel Theme — Dark or Light, adapts to chart background.

🛠️ HOW TO USE

1. Add the script to your chart at the start of each trading day (or leave it on permanently — it refreshes automatically).
2. Read the dashboard panel top to bottom: LEVELS tell you where the battle lines are, BIAS tells you the dominant direction, VOLATILITY tells you how much room the market has, PLANS give you conditional playbooks for the day.
3. Check the "Risk Note" line — it adapts to the volatility regime and bias. Low volatility suggests patience, high volatility suggests reducing size, neutral bias suggests waiting for a clean break.
4. Use the plotted levels as structural references for your own entries and exits. The projected range box highlights where mean-reversion trades are statistically more likely to work.
5. Set alerts on PDH/PDL breaks and projected-range expansion events to get notified when your Plan A or Plan B is being tested.
6. Adjust the bias mode to match your style: intraday scalpers benefit from Fast (HTF-weighted), position traders often prefer Conservative (MTF-weighted).

⚠️ LIMITATIONS & TRANSPARENCY

• This is a briefing tool, not a strategy or signal generator. It does not open, close, or manage trades.
• All levels and plans are derived from historical data (previous day/week highs and lows, ATR, EMA structure). Past structure does not guarantee future behavior.
• Projected ranges are statistical estimates based on ATR — actual daily ranges can and do exceed them, especially during news events or regime shifts.
• The multi-timeframe bias score is a momentum/trend structure measurement, not a prediction. Markets can reverse at any time regardless of bias.
• Plan language uses historical-pattern framing deliberately. No plan is a forecast; it is a conditional reference for discretionary decision-making.
• On weekly and higher timeframes, PDH/PDL are hidden by design because "previous day" is not a meaningful unit for weekly-horizon decisions. Plan A and Plan B use PWH/PWL as reference in those cases.
• The script does not repaint on closed higher-timeframe bars. The daily open, PDH, PDL, PWH, PWL are locked once the respective higher-timeframe bar closes.
• Round-number auto-detection uses price magnitude; for unusual instruments (very high or very low priced), review the levels manually.

🛡️ RISK DISCLOSURE

Trading involves substantial risk of loss. This script is a technical analysis tool provided for informational and educational purposes only. It does not constitute financial advice, investment recommendations, or a solicitation to trade any instrument. Past performance of any pattern, level, or methodology shown is not indicative of future results. Always conduct your own analysis, manage your position size according to your risk tolerance, and consider consulting a qualified financial professional before making trading decisions. The author and AGProLabs assume no liability for any trading outcomes resulting from the use of this tool.
הערות שחרור
🔧 UPDATE NOTES - V1.1

This update focuses on visual planning clarity, chart-first decision flow, and daily plan usability.

The core purpose of the script remains unchanged.
This release improves how the existing daily plan logic is presented, organized, and interpreted on the chart.

This script continues to function as an analytical and visualization tool.
It does not attempt to predict price direction or provide guaranteed outcomes.


------------------------
What Changed
------------------------

• Added Session Plan Box
The chart now displays a dedicated session planning area between the active risk line and projected target reference.

• Added Daily Plan Quality Engine
The script now calculates a 0-100 plan quality score using open relation, bias confirmation, volatility state, invalidation distance, and target room.

• Added No-Trade Zone
A compact open-range zone highlights where the daily plan should remain inactive until price leaves the neutral area.

• Added Action-State Logic
The script now classifies the plan as Active, No-Trade, Blocked, Review, Neutral, or Invalidated.

• Added Risk Line and Target Room Context
The plan now includes a clearer invalidation reference and a target-room readout directly connected to the daily plan state.


------------------------
Visual Improvements
------------------------

• Improved chart readability with a session plan box, centered no-trade zone label, and clearer risk/target references.

• Reduced panel weight by replacing the older full dashboard with a compact decision panel.

• Shortened Plan A / Plan B labels so the chart feels cleaner and more premium.

• Adjusted label placement to keep the active plan state visible outside the candle body area.

• Refined default scenario density and label staggering after chart review to reduce overlap around the plan box and risk line.


------------------------
Interface & Usability
------------------------

• Optimized panel layout around the required decision rows: Daily Bias, Plan Quality, Risk Line, Target Room, and Action.

• Added Plan Engine inputs for sensitivity, confirmation mode, minimum quality, no-trade width, and risk-line distance.

• Kept panel visibility, panel location, panel theme, panel font size, and label font size configurable.

• Preserved the AGPro header standard: a single merged blue first row with only the panel title.


------------------------
Behavior Notes
------------------------

This update does not change the original identity of Daily Trade Plan Generator.

The goal is to make the existing planner more visual, more actionable, and less panel-first.

Users should interpret the output as a structured daily planning context, not as an automatic trade instruction.


------------------------
Limitations Reminder
------------------------

The script remains a rule-based analytical tool.

Market conditions such as volatility, liquidity, session timing, and timeframe differences may affect how plan states appear.

Outputs should always be interpreted within broader market context.


------------------------
Risk Reminder
------------------------

This script is for educational and analytical purposes only.

It does not provide financial advice or guaranteed trading outcomes.

Users remain responsible for their own decisions.
הערות שחרור
🔧 UPDATE NOTES - v1.2

This update focuses on readability and a plan follow-through proof.

The core purpose of the script remains unchanged.
This release makes every on-chart label a filled, contrast-safe badge, centers
the plan and no-trade labels inside their zones, adds a stop-aware plan
activation proof to the panel, and hardens the ATR baseline. It does not change
the bias, plan-quality, risk, or target logic.

This script continues to function as an analytical and visualization tool.
It does not attempt to predict price direction or provide guaranteed outcomes.


------------------------
What Changed
------------------------

• Contrast-safe label badges
PDH/PDL, PWH/PWL, round-number, PROJ HI/LO, RISK, TARGET REF, plan-state,
scenario, and refresh labels are now solid filled badges whose text color is
chosen from each fill brightness, so every label stays legible instead of thin
colored text on a faded background.

• Centered zone badges
The session plan box and the no-trade box now carry a centered, filled badge
("SESSION" / "WAIT") inside the zone rather than faint box text.

• Plan activation proof added
When a daily plan turns Active, the script measures whether price followed
through in the plan direction (1.5 ATR) before reversing against it (1.0 ATR),
evaluated on confirmed closes from the activation bar. It reports the
follow-through share with the sample count, e.g. "54% (40)", and reads
"Building (n)" until at least 6 samples exist. This is a descriptive statistic,
not a win rate or signal.

• Hardened ATR baseline
The daily ATR used for projection, zones, and scoring now falls back safely on
early or illiquid bars, and a separate chart-timeframe ATR drives the proof.


------------------------
Visual Improvements
------------------------

• Improved label legibility across every level, plan, and scenario badge

• Plan and no-trade labels now sit centered inside their zones

• Right-edge level labels (PDH/PDL, PWH/PWL, round, PROJ HI/LO, RISK, TARGET REF)
now share one de-collision pass so they never stack on top of each other


------------------------
Interface & Usability
------------------------

• Panel now reads Daily Bias, Plan Quality, Risk Line, Target Room, Volatility,
Action, and Proof in a single decision flow

• Clearer first-glance reading of the active plan zone

• Enhanced overall user experience without changing the core engine


------------------------
Behavior Notes
------------------------

This update does not change the bias calculation, plan-quality scoring, risk
line, target reference, or state logic.

The Proof row is a historical, descriptive follow-through statistic measured on a
fixed symmetric ATR reference at confirmed closes from each plan activation. It
is not a forecast, win rate, or trade instruction, and it is symbol- and
timeframe-dependent.

Users should interpret outputs the same way as before, now with clearer badges
and a follow-through context read.


------------------------
Limitations Reminder
------------------------

The script remains a rule-based analytical tool.

Market conditions such as volatility, liquidity, and timeframe differences may
affect how plans form and how the proof rate reads.

Outputs should always be interpreted within broader market context.


------------------------
Risk Reminder
------------------------

This script is for educational and analytical purposes only.

It does not provide financial advice or guaranteed trading outcomes.

Users remain responsible for their own decisions.
הערות שחרור
Version 1.3 – Baseline Integrity

This release preserves the original Daily Trade Plan Generator layout, panel, session map, scenario placement, and visual rhythm while applying a focused stability and ownership refinement. The bias, plan-quality, state, risk, target-room, and proof engines remain unchanged.

• Daily ATR projections now use the last completed daily ATR value, preventing the active day’s developing range from shifting the morning baseline.

• Refresh, plan-state, invalidation, follow-through, PDH/PDL, and projected-range events are now restricted to confirmed bars.

• Coincident daily and weekly levels share one combined badge and one visible line owner, removing exact duplicate references without reducing the complete map.

• The directional target now owns its matching projected edge through one TARGET / PROJ HI or TARGET / PROJ LO badge, eliminating the duplicated right-edge price.

• WAIT and Plan Updated badges now follow the shared Label Font Size setting instead of using a hardcoded size.

• The original Zone default, SESSION badge, external plan-state badge, Plan A/B/C placement, full key-level map, and eight-row dashboard remain intact.

כתב ויתור

המידע והפרסומים אינם מיועדים להיות, ואינם מהווים, ייעוץ או המלצה פיננסית, השקעתית, מסחרית או מכל סוג אחר המסופקת או מאושרת על ידי TradingView. קרא עוד ב־תנאי השימוש.