Actualizado
Price Action Time Segments [M1D]

Price Action Time Segments (PATS)
==================================
OVERVIEW
--------
Price Action Time Segments (PATS) is a time-based visual analysis tool designed to segment the trading day into clearly defined, labelled time windows directly on the chart. Rather than cluttering the screen with calculated signals, PATS renders coloured, adjustable time segments as background zones or session boxes that give the trader an immediate, at-a-glance reference for which phase of the trading day is active. Each segment is independently configurable — colour, opacity, allowing the tool to adapt to any trading session, instrument, or methodology.
WHAT IT DOES
------------
PATS divides the 24-hour trading day into distinct, user-defined time blocks and renders each block as a coloured region on the chart. Labels are drawn at the opening edge of each segment, identifying the period by name. The tool is fully timezone-aware: the user selects their local timezone from the settings panel, and all segment boundaries are plotted relative to that offset, ensuring the segments remain correctly aligned regardless of the chart's base timezone or which broker feed is in use.
Each segment can be toggled on or off independently, enabling traders to display only the time windows relevant to their specific strategy. The tool does not generate buy or sell signals. It does not calculate any lagging or leading mathematical indicator. Its sole function is to provide a time-structured, visual map of the trading day against raw price action.
HOW IT WORKS
------------
On each confirmed bar, PATS evaluates whether the current bar's session time falls within any of the user-configured time windows. When a new segment begins, the indicator draws a box spanning from the segment's open to its close at the high and low of that window's range — or optionally as a full-height background band. The box extends bar by bar until the segment's end time is reached, at which point it is closed and locked. A text label is positioned at the left edge of the segment identifying it by the user-supplied name.
Because all rendering is anchored to confirmed bars and session timestamps rather than lookahead or repainting calculations, the segments are historically stable. What was drawn at any prior bar remains exactly where it was drawn.
The tool maintains a rolling object store, cleaning up older segment drawings to stay within TradingView's object limits while retaining a configurable number of historical instances. This means traders can scroll back through chart history and still see a useful number of prior sessions clearly delineated.
UNDERLYING CONCEPT — WHY TIME MATTERS IN PRICE ACTION
------------------------------------------------------
Markets are not random across time. Liquidity, volatility, and institutional order flow are heavily concentrated within specific windows of the trading day. The overlap of major financial centres — particularly London and New York — produces the highest volume and most significant price displacement. Conversely, periods between sessions often see consolidation, false moves, and reduced follow-through.
Many price action disciplines — including time-based models rooted in institutional order flow analysis — use the structure of the trading day as a primary filter. The idea is that a valid setup occurring during a high-probability time window carries more weight than the same technical structure forming during a low-activity period. PATS makes this time-awareness immediately visible without requiring the trader to cross-reference a separate clock or calendar.
Common time segments traders configure include:
- Asian session (late evening / overnight range in Western timezones)
- London open and the early European session
- New York open and the AM session through to midday
- The overlap between London close and New York AM
- Lunch or low-liquidity consolidation windows (typically midday New York)
- New York PM session and end-of-day fixings
Traders studying intraday models that reference specific macro windows — for example, opening ranges defined by the first 15 or 30 minutes of a session, or time-of-day ranges used to frame the day's directional narrative — will find PATS useful as a visual anchor for those frameworks.
HOW TO USE IT
-------------
1. Enable or disable individual segments using the toggle next to each one. This allows you to quickly switch between different configurations without deleting your saved settings.
2. Adjust the opacity of segment boxes to suit your chart style. Lower opacity keeps the price action visible while still providing clear time delineation.
3. Scroll back through history to review how price behaved within each segment across multiple sessions.
USE CASES
---------
Session Context: Traders who operate across multiple instruments or timezones use PATS to instantly see which session is active and what the session's high and low have been so far, without switching between charts.
Kill Zone Mapping: Intraday traders who focus on specific high-activity windows can configure segments to highlight those windows, making it visually obvious when they are inside or outside their preferred trading hours.
AMD Framework Visualisation: Traders using accumulation-manipulation-distribution models can segment the day into the three phases — typically the Asian range (accumulation), the London spike (manipulation), and the New York session (distribution) — and review how price behaved in each phase historically.
Opening Range Analysis: By configuring a segment to cover the first 15 or 30 minutes of a session, traders can visually assess how the day's range developed relative to its opening period across multiple historical days.
Session High/Low Tracking: Each segment box naturally tracks the high and low of that time window as it develops in real time, giving traders a simple reference for the session's range without needing a separate script.
Backreview and Journaling: Traders reviewing past sessions can scroll back and immediately identify what time of day each candle belongs to, which simplifies the process of pattern recognition and post-session analysis.
SETTINGS
--------
- Colour: Set the background colour for each segment.
- Opacity: Control the transparency of each segment box (0 = invisible, 100 = solid).
- Show Segment: Toggle the entire segment on or off without removing its configuration.
- History Count: Set how many historical instances of each segment are retained on the chart.
LIMITATIONS AND NOTES
---------------------
- PATS is a visualisation tool only. It does not provide signals, predictions, or trading recommendations of any kind.
- Past session behaviour does not guarantee future price action. Time-based patterns reflect statistical tendencies, not certainties.
- On very low timeframes (sub-1-minute), segment boxes may produce a high number of drawing objects. Reduce the history count setting if performance is affected.
- Segment boundaries are based on the chart instrument's session data and the user-selected timezone. Verify alignment on instruments with non-standard market hours (e.g. crypto, which trades continuously) or instruments traded across multiple exchanges.
This script is published open-source. Traders are welcome to use the code, adapt it to their needs, and use it as a reference for time-based session rendering in Pine Script v6.
==================================
OVERVIEW
--------
Price Action Time Segments (PATS) is a time-based visual analysis tool designed to segment the trading day into clearly defined, labelled time windows directly on the chart. Rather than cluttering the screen with calculated signals, PATS renders coloured, adjustable time segments as background zones or session boxes that give the trader an immediate, at-a-glance reference for which phase of the trading day is active. Each segment is independently configurable — colour, opacity, allowing the tool to adapt to any trading session, instrument, or methodology.
WHAT IT DOES
------------
PATS divides the 24-hour trading day into distinct, user-defined time blocks and renders each block as a coloured region on the chart. Labels are drawn at the opening edge of each segment, identifying the period by name. The tool is fully timezone-aware: the user selects their local timezone from the settings panel, and all segment boundaries are plotted relative to that offset, ensuring the segments remain correctly aligned regardless of the chart's base timezone or which broker feed is in use.
Each segment can be toggled on or off independently, enabling traders to display only the time windows relevant to their specific strategy. The tool does not generate buy or sell signals. It does not calculate any lagging or leading mathematical indicator. Its sole function is to provide a time-structured, visual map of the trading day against raw price action.
HOW IT WORKS
------------
On each confirmed bar, PATS evaluates whether the current bar's session time falls within any of the user-configured time windows. When a new segment begins, the indicator draws a box spanning from the segment's open to its close at the high and low of that window's range — or optionally as a full-height background band. The box extends bar by bar until the segment's end time is reached, at which point it is closed and locked. A text label is positioned at the left edge of the segment identifying it by the user-supplied name.
Because all rendering is anchored to confirmed bars and session timestamps rather than lookahead or repainting calculations, the segments are historically stable. What was drawn at any prior bar remains exactly where it was drawn.
The tool maintains a rolling object store, cleaning up older segment drawings to stay within TradingView's object limits while retaining a configurable number of historical instances. This means traders can scroll back through chart history and still see a useful number of prior sessions clearly delineated.
UNDERLYING CONCEPT — WHY TIME MATTERS IN PRICE ACTION
------------------------------------------------------
Markets are not random across time. Liquidity, volatility, and institutional order flow are heavily concentrated within specific windows of the trading day. The overlap of major financial centres — particularly London and New York — produces the highest volume and most significant price displacement. Conversely, periods between sessions often see consolidation, false moves, and reduced follow-through.
Many price action disciplines — including time-based models rooted in institutional order flow analysis — use the structure of the trading day as a primary filter. The idea is that a valid setup occurring during a high-probability time window carries more weight than the same technical structure forming during a low-activity period. PATS makes this time-awareness immediately visible without requiring the trader to cross-reference a separate clock or calendar.
Common time segments traders configure include:
- Asian session (late evening / overnight range in Western timezones)
- London open and the early European session
- New York open and the AM session through to midday
- The overlap between London close and New York AM
- Lunch or low-liquidity consolidation windows (typically midday New York)
- New York PM session and end-of-day fixings
Traders studying intraday models that reference specific macro windows — for example, opening ranges defined by the first 15 or 30 minutes of a session, or time-of-day ranges used to frame the day's directional narrative — will find PATS useful as a visual anchor for those frameworks.
HOW TO USE IT
-------------
1. Enable or disable individual segments using the toggle next to each one. This allows you to quickly switch between different configurations without deleting your saved settings.
2. Adjust the opacity of segment boxes to suit your chart style. Lower opacity keeps the price action visible while still providing clear time delineation.
3. Scroll back through history to review how price behaved within each segment across multiple sessions.
USE CASES
---------
Session Context: Traders who operate across multiple instruments or timezones use PATS to instantly see which session is active and what the session's high and low have been so far, without switching between charts.
Kill Zone Mapping: Intraday traders who focus on specific high-activity windows can configure segments to highlight those windows, making it visually obvious when they are inside or outside their preferred trading hours.
AMD Framework Visualisation: Traders using accumulation-manipulation-distribution models can segment the day into the three phases — typically the Asian range (accumulation), the London spike (manipulation), and the New York session (distribution) — and review how price behaved in each phase historically.
Opening Range Analysis: By configuring a segment to cover the first 15 or 30 minutes of a session, traders can visually assess how the day's range developed relative to its opening period across multiple historical days.
Session High/Low Tracking: Each segment box naturally tracks the high and low of that time window as it develops in real time, giving traders a simple reference for the session's range without needing a separate script.
Backreview and Journaling: Traders reviewing past sessions can scroll back and immediately identify what time of day each candle belongs to, which simplifies the process of pattern recognition and post-session analysis.
SETTINGS
--------
- Colour: Set the background colour for each segment.
- Opacity: Control the transparency of each segment box (0 = invisible, 100 = solid).
- Show Segment: Toggle the entire segment on or off without removing its configuration.
- History Count: Set how many historical instances of each segment are retained on the chart.
LIMITATIONS AND NOTES
---------------------
- PATS is a visualisation tool only. It does not provide signals, predictions, or trading recommendations of any kind.
- Past session behaviour does not guarantee future price action. Time-based patterns reflect statistical tendencies, not certainties.
- On very low timeframes (sub-1-minute), segment boxes may produce a high number of drawing objects. Reduce the history count setting if performance is affected.
- Segment boundaries are based on the chart instrument's session data and the user-selected timezone. Verify alignment on instruments with non-standard market hours (e.g. crypto, which trades continuously) or instruments traded across multiple exchanges.
This script is published open-source. Traders are welcome to use the code, adapt it to their needs, and use it as a reference for time-based session rendering in Pine Script v6.
Notas de prensa
Publishing Updates Applied:1. Colors
Optimized for both white and dark chart backgrounds (good contrast without being too bright or too dark)
AMD boxes now use:
A (Accumulation) = Blue
M (Manipulation) = Red
D (Distribution) = Green
All time segments are able to be custom colored to your own specific preference or made all the same for less distractions
2. Default Settings
showAMDBoxes = true (AMD boxes now enabled by default)
show12H = true
show1H = true
3. Table Styling
Changed to black background with white text for better readability
4. Overall Polish
All features included and working:
HTF Range Boxes (15m, 1H, 4H, 12H, Daily, 3D, Weekly)
EQ Midlines on most recent + developing box
Standalone AMD Phase Boxes on chart
Editable labels for everything
Top-right info table (TFs, box count, hours visualized, current AMD phase)
show1H = input.bool(true, "1H", group=groupTF)
show12H = input.bool(true, "12H", group=groupTF)
showAMDBoxes = input.bool(true, "Show AMD Phase Boxes on Chart", group=groupAMD)
colA = input.color(#2196F3, "Accumulation (A)", group=groupColors)
colM = input.color(#E53935, "Manipulation (M)", group=groupColors)
colD2 = input.color(#43A047, "Distribution (D)", group=groupColors)
var table infoTbl = table.new(position.top_right, 5, 12,
bgcolor = color.new(#000000, 15),
frame_color = #000000,
border_color = #333333,
border_width = 1)
Notas de prensa
{Visual Cleanup Update}Will add custom time logic on the AMD Phases soon & Label Positioning.
Notas de prensa
Update Notes — ICT PATS AMD (M1D)Fixes:
AMD phase boxes (Accumulation/Manipulation/Distribution) now correctly contain all price action within each session — previously some wicks could appear outside the box on certain chart timeframes.
AMD phase timing is now locked to New York time, matching standard ICT convention, regardless of the instrument's exchange or your chart's timezone setting.
Completed boxes now display with a solid border; only the currently-developing box uses a dashed border, so you can tell at a glance what's still forming.
New:
Added label position control for the higher-timeframe range boxes (15m–Weekly) — choose top-left, top-right, centered, etc. Useful for keeping labels visible on wider Daily/3D/Weekly boxes.
The info table now displays the live equilibrium (EQ) price for each timeframe instead of a placeholder symbol.
Note: Occasional one-bar visual quirks around U.S. market holidays (e.g. early-close days) reflect the exchange's own adjusted trading calendar, not an indicator error — these resolve automatically the following week.
Notas de prensa
UPDATE:Updated the colour scheme + the dashboard to reflect the chart and what is running on the chart currently to be the only visible zones on the table to reduce clutter.
No logic touched.
Notas de prensa
A cleaner chart on first addThe 4H and daily boxes and the AMD phase boxes draw by default. 15m, 1H and 12H are off, one switch each away.
Box names above the box
Each box's name sits centred above its top edge instead of inside it, so it no longer lands on price. Every box shares one black border and the fill carries which timeframe or phase it is. Fills are lighter, so overlapping boxes still read as separate boxes.
New 4H and 3D colours
4H is orange and 3D is brown, so no time box wears the purple or magenta that mean direction elsewhere in the suite. Daily and weekly boxes are black.
Thinner EQ midlines
Midlines draw dotted at width 1 in their box's colour.
A two-column table
The table shows the current AMD phase, then the EQ of each timeframe that is switched on. Hover a timeframe row for how many boxes are on the chart and the hours they cover. It sits bottom centre by default, and one text size setting sets the box names and the table.
The box label position settings are gone. Reset the indicator to its defaults once so saved values line up with the right inputs.
Exención de responsabilidad
La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.
Exención de responsabilidad
La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.