OPEN-SOURCE SCRIPT
Tokyo & London Pre-Market Boxes (Local Time)

//version=5
indicator("Daily 10am & 6pm Lines", overlay=true)
var line line10 = na
var line line18 = na
// Convert 10:00 and 18:00 into timestamps for today
t10 = timestamp(year, month, dayofmonth, 10, 0)
t18 = timestamp(year, month, dayofmonth, 18, 0)
// When the bar’s time crosses 10:00, draw a vertical line
if (time >= t10 and time[1] < t10)
line10 := line.new(x1 = t10, y1 = low, x2 = t10, y2 = high, color=color.blue, width = 1)
// When the bar’s time crosses 18:00 (6pm), draw another line
if (time >= t18 and time[1] < t18)
line18 := line.new(x1 = t18, y1 = low, x2 = t18, y2 = high, color=color.red, width = 1)
indicator("Daily 10am & 6pm Lines", overlay=true)
var line line10 = na
var line line18 = na
// Convert 10:00 and 18:00 into timestamps for today
t10 = timestamp(year, month, dayofmonth, 10, 0)
t18 = timestamp(year, month, dayofmonth, 18, 0)
// When the bar’s time crosses 10:00, draw a vertical line
if (time >= t10 and time[1] < t10)
line10 := line.new(x1 = t10, y1 = low, x2 = t10, y2 = high, color=color.blue, width = 1)
// When the bar’s time crosses 18:00 (6pm), draw another line
if (time >= t18 and time[1] < t18)
line18 := line.new(x1 = t18, y1 = low, x2 = t18, y2 = high, color=color.red, width = 1)
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
إخلاء المسؤولية
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.
نص برمجي مفتوح المصدر
بروح TradingView الحقيقية، قام مبتكر هذا النص البرمجي بجعله مفتوح المصدر، بحيث يمكن للمتداولين مراجعة وظائفه والتحقق منها. شكرا للمؤلف! بينما يمكنك استخدامه مجانًا، تذكر أن إعادة نشر الكود يخضع لقواعد الموقع الخاصة بنا.
إخلاء المسؤولية
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.