OPEN-SOURCE SCRIPT
Opening Range Box, 2 Sessions

Opening Range & Session Box Indicator
This indicator automatically draws Opening Range (OR) boxes and Session Boxes based on specific time zone settings, helping you visualize key trading periods across different global markets.
Key Features:
Custom Sessions: Define two independent trading sessions (e.g., New York and London).
Time Zone Selection: Choose the exact time zone for each session from a simple dropdown menu, ensuring accurate session mapping regardless of your chart's time zone.
Opening Range Definition: The initial portion of each session (defined by the Opening Range Minutes input) establishes the high and low of the box.
Offset Lines: Automatically draws two percentage offset lines inside the box, allowing you to easily track price movement relative to the Opening Range high and low (e.g., 10% retracement levels).
How to Use the Inputs:
Session A/B Timezone - Select the time zone for Session A (e.g., America/New_York).
Session A/B Time - Define the start and end time for Session A (e.g., 0930-1600).
Opening Range Minutes - Set how long the initial opening range period lasts (e.g., 30 minutes).
Percent from High/Low for Line - Set the percentage distance for the inner offset lines (e.g., 10.0 for 10% retracement).
Number of Boxes to Show - Controls the number of historical session boxes and lines that remain visible on the chart.
This indicator automatically draws Opening Range (OR) boxes and Session Boxes based on specific time zone settings, helping you visualize key trading periods across different global markets.
Key Features:
Custom Sessions: Define two independent trading sessions (e.g., New York and London).
Time Zone Selection: Choose the exact time zone for each session from a simple dropdown menu, ensuring accurate session mapping regardless of your chart's time zone.
Opening Range Definition: The initial portion of each session (defined by the Opening Range Minutes input) establishes the high and low of the box.
Offset Lines: Automatically draws two percentage offset lines inside the box, allowing you to easily track price movement relative to the Opening Range high and low (e.g., 10% retracement levels).
How to Use the Inputs:
Session A/B Timezone - Select the time zone for Session A (e.g., America/New_York).
Session A/B Time - Define the start and end time for Session A (e.g., 0930-1600).
Opening Range Minutes - Set how long the initial opening range period lasts (e.g., 30 minutes).
Percent from High/Low for Line - Set the percentage distance for the inner offset lines (e.g., 10.0 for 10% retracement).
Number of Boxes to Show - Controls the number of historical session boxes and lines that remain visible on the chart.
Skrip sumber terbuka
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Penafian
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.
Skrip sumber terbuka
In true TradingView spirit, the creator of this script has made it open-source, so that traders can review and verify its functionality. Kudos to the author! While you can use it for free, remember that republishing the code is subject to our House Rules.
Penafian
The information and publications are not meant to be, and do not constitute, financial, investment, trading, or other types of advice or recommendations supplied or endorsed by TradingView. Read more in the Terms of Use.