The Fibonacci Opening Range (FOR) is a technical indicator that uses the market’s opening session to define key support and resistance levels based on Fibonacci ratios. This indicator helps traders identify high-probability zones for potential reversals or trend continuations by analyzing the initial movement of the trading session.
The opening range refers to the highest and lowest prices reached during the first minutes or hours of the trading session. These levels are essential as they often mark significant support and resistance areas for the rest of the day.
The Fibonacci Opening Range indicator extends these levels using Fibonacci ratios such as 1.618 and 2.618 to project potential price extensions above and below the range.
The indicator follows these steps:
The FOR indicator includes customizable settings for a more personalized experience:
ORBegin: Start time of the opening range (e.g., 9:00 AM).OREnd: End time of the opening range (e.g., 10:00 AM).ShowpastFibo: Option to display Fibonacci extensions throughout the day.Fibonacci levels provide critical information about potential price movements:
//--------------------------------------------//
//PRC_Fibonacci Open Range
//version = 0
//13.01.2025
//Iván González @ www.prorealcode.com
//Sharing ProRealTime knowledge
//--------------------------------------------//
// inputs
//--------------------------------------------//
//ORBegin=090000
//OREnd=100000
//ShowpastFibo=1
//--------------------------------------------//
// Calculate Open Range
//--------------------------------------------//
if gettimeframe<=3600 then
once ORHigh=0
once ORLow=9999999
// Puntos de Fibonacci
ORWidth = ORHigh - ORLow
FibMid = (ORHigh + ORLow) / 2
FibExtUp1 = ORHigh + ORWidth * (1.0)
FibExtDown1 = ORLow - ORWidth * (1.0)
FibExtUp2 = ORHigh + ORWidth * (1.618)
FibExtDown2 = ORLow - ORWidth * (1.618)
FibExtUp3 = ORHigh + ORWidth * (2.0)
FibExtDown3 = ORLow - ORWidth * (2.0)
FibExtUp4 = ORHigh + ORWidth * (2.618)
FibExtDown4 = ORLow - ORWidth * (2.618)
FibExtUp5 = ORHigh + ORWidth * (3.618)
FibExtDown5 = ORLow - ORWidth * (3.618)
FibExtUp6 = ORHigh + ORWidth * (4.236)
FibExtDown6 = ORLow - ORWidth * (4.236)
if opentime>=ORBegin and opentime[1]<ORBegin then
drawsegment(OREndIdx,ORHigh,barindex,ORHigh)coloured("red")style(line,1)
drawsegment(OREndIdx,ORLow,barindex,ORLow)coloured("green")style(line,1)
drawsegment(OREndIdx,FibMid,barindex,FibMid)coloured("blue")style(dottedline,1)
drawsegment(OREndIdx,ORLow,barindex,ORLow)coloured("green")style(line,1)
if ShowpastFibo then
drawsegment(OREndIdx,FibExtDown1,barindex,FibExtDown1)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown2,barindex,FibExtDown2)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown3,barindex,FibExtDown3)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown4,barindex,FibExtDown4)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown5,barindex,FibExtDown5)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown6,barindex,FibExtDown6)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp1,barindex,FibExtUp1)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp2,barindex,FibExtUp2)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp3,barindex,FibExtUp3)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp4,barindex,FibExtUp4)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp5,barindex,FibExtUp5)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp6,barindex,FibExtUp6)coloured("red")style(dottedline,1)
endif
ORHigh=high
ORLow=low
ORBeginIdx=barindex
drawvline(barindex)style(dottedline3)coloured("grey")
elsif opentime>=ORBegin and opentime<=OREnd then
ORHigh=max(ORHigh,high)
ORLow=min(ORLow,low)
elsif opentime>OREnd and opentime[1]<=OREnd then
OREndIdx=barindex[1]
drawsegment(ORBeginIdx,ORHigh,OREndIdx,ORHigh)coloured("red")style(line,3)
drawsegment(ORBeginIdx,ORLow,OREndIdx,ORLow)coloured("green")style(line,3)
elsif islastbarupdate then
drawsegment(barindex+10,ORHigh,OREndIdx,ORHigh)coloured("red")style(line,1)
drawsegment(barindex+10,ORLow,OREndIdx,ORLow)coloured("green")style(line,1)
drawsegment(OREndIdx,FibMid,barindex+10,FibMid)coloured("blue")style(dottedline,1)
drawsegment(OREndIdx,ORLow,barindex+10,ORLow)coloured("green")style(line,1)
drawsegment(OREndIdx,FibExtDown1,barindex+10,FibExtDown1)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown2,barindex+10,FibExtDown2)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown3,barindex+10,FibExtDown3)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown4,barindex+10,FibExtDown4)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown5,barindex+10,FibExtDown5)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtDown6,barindex+10,FibExtDown6)coloured("green")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp1,barindex+10,FibExtUp1)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp2,barindex+10,FibExtUp2)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp3,barindex+10,FibExtUp3)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp4,barindex+10,FibExtUp4)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp5,barindex+10,FibExtUp5)coloured("red")style(dottedline,1)
drawsegment(OREndIdx,FibExtUp6,barindex+10,FibExtUp6)coloured("red")style(dottedline,1)
else
ORHigh=ORHigh
ORLow=ORLow
endif
endif
//--------------------------------------------//
return