RicardoSantos

[RS]Session Open Price Levels V0

290 0 50
EXPERIMENTAL: theres some issues, like not being able to read sidney's open bar on the start of the week, so use this cautiously :p
Remove from Favorite Scripts Add to Favorite Scripts
study(title="[RS]Session Open Price Levels V0", shorttitle="[RS]SOPL.V0", overlay=true)
sidney_hours = "1700-0300", sidney_open = "1600-1601"
tokyo_hours = "1900-0400", tokyo_open = "1800-1801"
london_hours = "0300-1200", london_open = "0200-0201"
newyork_hours = "0800-1700", newyork_open = "0700-0701"

sidneyprice = time("1", sidney_open) ? open : time("1", sidney_hours) ? sidneyprice[1] : na
tokyoprice = time("1", tokyo_open) ? open : time("1", tokyo_hours) ? tokyoprice[1] : na
londonprice = time("1", london_open) ? open : time("1", london_hours) ? londonprice[1] : na
newyorkprice = time("1", newyork_open) ? open : time("1", newyork_hours) ? newyorkprice[1] : na

sidneycolor = time("1", sidney_hours) ? black : na
tokyocolor = time("1", tokyo_hours) ? teal : na
londoncolor = time("1", london_hours) ? blue : na
newyorkcolor = time("1", newyork_hours) ? navy : na

plot(sidneyprice, color=sidneycolor, linewidth=2)
plot(tokyoprice, color=tokyocolor, linewidth=2)
plot(londonprice, color=londoncolor, linewidth=2)
plot(newyorkprice, color=newyorkcolor, linewidth=2)

Related Ideas

Ideas Scripts Chart
United States
United Kingdom
India
España
Italia
Brasil
Россия
Türkiye
日本
한국
Home Stock Screener Economic Calendar How It Works Chart Features House Rules Moderators For the WEB Widgets Stock Charting Library Priority Support Feature Request Blog & News FAQ Help & Wiki Twitter
Private Messages Chat Ideas Published Followers Following Priority Support Public Profile Profile Settings Account and Billing Sign Out