Futuraman

GS_Opening-Range-V1

ORB Opening Range Breakout 5 and 3O Minute Indicator

Kudos to Chris Moody for the inspiration to create my first indicator.

The 5 and 30 run together at times but the scalp would be when the equity breaks the 5 go long or short for the scalp and when it breaks the 30 go for the swing trade.
نص برمجي مفتوح المصدر

قام مؤلف هذا النص البرمجي بنشره وجعله مفتوح المصدر، بحيث يمكن للمتداولين فهمه والتحقق منه، وهو الأمر الذي يدخل ضمن قيم TradingView. تحياتنا للمؤلف! يمكنك استخدامه مجانًا، ولكن إعادة استخدام هذا الكود في منشور تحكمه قواعد الموقع. يمكنك جعله مفضلاً لاستخدامه على الرسم البياني.

إخلاء المسؤولية

لا يُقصد بالمعلومات والمنشورات أن تكون، أو تشكل، أي نصيحة مالية أو استثمارية أو تجارية أو أنواع أخرى من النصائح أو التوصيات المقدمة أو المعتمدة من TradingView. اقرأ المزيد في شروط الاستخدام.

هل تريد استخدام هذا النص البرمجي على الرسم البياني؟
study(title="GS_Opening-Range-V1", shorttitle="GS_OpenRnge-V1", overlay=true)

up30on = input(false, title="30 Minute Opening Range High")
down30on = input(false, title="30 Minute Opening Range Low")
up5on = input(true, title="5 Minute Opening Range High")
down5on = input(true, title="5 Minute Opening Range Low")
is_newbar(res) => change(time(res)) != 0 
adopt(r, s) => security(tickerid, r, s) 

high_range = valuewhen(is_newbar('D'),high,0)
low_range = valuewhen(is_newbar('D'),low,0)

high_rangeL = valuewhen(is_newbar('D'),high,0) 
low_rangeL = valuewhen(is_newbar('D'),low,0) 

up = plot(up5on ? adopt('5', high_range):na, color = lime, style=circles, linewidth=4)
down = plot(down5on ? adopt('5', low_range): na, color = #DC143C, style=circles, linewidth=4) 

trans30 = up30on ?  75 : 100
fill(up, down, color = white, transp=trans30)

up30 = plot(up30on ? adopt('30', high_rangeL): na, color = #7FFF00, style=circles, linewidth=2) 
down30 = plot(down30on ? adopt('30', low_rangeL): na, color = red, style=circles, linewidth=2)