OPEN-SOURCE SCRIPT
DAILY AND WEEKLY MID LINES

DAILY AND WEEKLY MID LINES INDICATOR
Description:
This indicator calculates and visualizes the dynamic midpoint (mid) of the current day and week in real-time. It provides traders with key reference levels based on developing price action.
Features:
Daily Mid Line:
Color: Orange
Thickness: 3 pixels
Style: Solid line
Updates: Automatically recalculates with each new candle
Calculation: Average of the day's highest high and lowest low from market open
Weekly Mid Line:
Color: Blue
Thickness: 3 pixels
Style: Dashed line
Updates: Continuously recalculates throughout the week
Calculation: Average of the week's highest high and lowest low from week start
How It Works:
At the start of each new trading day (00:00), the daily mid line resets and begins calculating from the first candle
At the start of each new trading week (typically Monday), the weekly mid line resets and begins fresh calculations
Both lines extend automatically to the right as new candles form
The lines are dynamic - they adjust as new highs/lows are made during the day/week
Trading Applications:
Support/Resistance Levels:
The mid lines act as natural equilibrium points where price may find temporary support or resistance
Daily mid can serve as intraday pivot, weekly mid as broader market balance point
Trend Analysis:
Price consistently above mid lines suggests bullish momentum
Price consistently below mid lines suggests bearish momentum
Relationship between daily and weekly mid lines shows multi-timeframe alignment
Entry/Exit Signals:
Price crossing above daily mid may indicate short-term bullish momentum
Price crossing below daily mid may indicate short-term bearish momentum
Weekly mid breaks can signal more significant trend changes
Market Context:
Distance between price and mid lines indicates market extremity
Steeper mid line slopes suggest stronger directional momentum
Flat mid lines suggest range-bound or consolidating markets
Confluence Trading:
Combine with other indicators (RSI, MACD, moving averages) for confirmation
Use as dynamic levels for stop-loss placement or take-profit targets
Best Practices:
More effective on higher timeframes (1H, 4H, Daily) for clearer signals
Works well in trending markets where mid lines act as moving support/resistance
Monitor for price rejection or acceptance at mid levels for trading decisions
Use in conjunction with volume analysis for confirmation
Psychological Significance:
Mid points often represent fair value areas where buyers and sellers find temporary equilibrium, making them natural decision points for market participants.
This indicator is particularly useful for day traders, swing traders, and position traders looking for dynamic, real-time reference points that adapt to current market conditions rather than relying on static historical levels.
Description:
This indicator calculates and visualizes the dynamic midpoint (mid) of the current day and week in real-time. It provides traders with key reference levels based on developing price action.
Features:
Daily Mid Line:
Color: Orange
Thickness: 3 pixels
Style: Solid line
Updates: Automatically recalculates with each new candle
Calculation: Average of the day's highest high and lowest low from market open
Weekly Mid Line:
Color: Blue
Thickness: 3 pixels
Style: Dashed line
Updates: Continuously recalculates throughout the week
Calculation: Average of the week's highest high and lowest low from week start
How It Works:
At the start of each new trading day (00:00), the daily mid line resets and begins calculating from the first candle
At the start of each new trading week (typically Monday), the weekly mid line resets and begins fresh calculations
Both lines extend automatically to the right as new candles form
The lines are dynamic - they adjust as new highs/lows are made during the day/week
Trading Applications:
Support/Resistance Levels:
The mid lines act as natural equilibrium points where price may find temporary support or resistance
Daily mid can serve as intraday pivot, weekly mid as broader market balance point
Trend Analysis:
Price consistently above mid lines suggests bullish momentum
Price consistently below mid lines suggests bearish momentum
Relationship between daily and weekly mid lines shows multi-timeframe alignment
Entry/Exit Signals:
Price crossing above daily mid may indicate short-term bullish momentum
Price crossing below daily mid may indicate short-term bearish momentum
Weekly mid breaks can signal more significant trend changes
Market Context:
Distance between price and mid lines indicates market extremity
Steeper mid line slopes suggest stronger directional momentum
Flat mid lines suggest range-bound or consolidating markets
Confluence Trading:
Combine with other indicators (RSI, MACD, moving averages) for confirmation
Use as dynamic levels for stop-loss placement or take-profit targets
Best Practices:
More effective on higher timeframes (1H, 4H, Daily) for clearer signals
Works well in trending markets where mid lines act as moving support/resistance
Monitor for price rejection or acceptance at mid levels for trading decisions
Use in conjunction with volume analysis for confirmation
Psychological Significance:
Mid points often represent fair value areas where buyers and sellers find temporary equilibrium, making them natural decision points for market participants.
This indicator is particularly useful for day traders, swing traders, and position traders looking for dynamic, real-time reference points that adapt to current market conditions rather than relying on static historical levels.
오픈 소스 스크립트
트레이딩뷰의 진정한 정신에 따라, 이 스크립트의 작성자는 이를 오픈소스로 공개하여 트레이더들이 기능을 검토하고 검증할 수 있도록 했습니다. 작성자에게 찬사를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 코드를 재게시하는 경우 하우스 룰이 적용된다는 점을 기억하세요.
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.
오픈 소스 스크립트
트레이딩뷰의 진정한 정신에 따라, 이 스크립트의 작성자는 이를 오픈소스로 공개하여 트레이더들이 기능을 검토하고 검증할 수 있도록 했습니다. 작성자에게 찬사를 보냅니다! 이 코드는 무료로 사용할 수 있지만, 코드를 재게시하는 경우 하우스 룰이 적용된다는 점을 기억하세요.
면책사항
해당 정보와 게시물은 금융, 투자, 트레이딩 또는 기타 유형의 조언이나 권장 사항으로 간주되지 않으며, 트레이딩뷰에서 제공하거나 보증하는 것이 아닙니다. 자세한 내용은 이용 약관을 참조하세요.