J’ai trouver le code sur le forum que j ai un peu tranformer pour qu il colle l ancien , je le poste pour si ca peut aider quelqu un.
TIMEFRAME (5 MINUTE)
TwoUp = high > high[1] and low > low[1]
TwoDown = low < low[1] and high < high[1]
InsideBar = high =< high[1] and low >= low[1]
OutsideBar = high > high[1] and low < low[1]
TIMEFRAME(DEFAULT)
C5 = close
If OpenMinute MOD 5 = 0 Then //Reset variables each new 5-minute bar
O5 = open
H5 = high
L5 = low
Else
H5 = max(H5,high)
L5 = min(L5,low)
Endif
If c5<o5 then
r=255
g=0
b=0
else
r=0
g=255
b=0
endif
If OpenMinute MOD 5 = 4 Then //plot only when the 5-minute bar closes
//Drawrectangle(BarIndex - 4,H5,BarIndex,L5) Coloured(r,g,b,255) //Body
//DrawRectangle(BarIndex - 2,max(O5,C5),BarIndex - 2,H5) Coloured(r,g,b,255) //Upper Wick
//DrawRectangle(BarIndex - 2,min(O5,C5),BarIndex - 2,L5) Coloured(r,g,b,255) //Lower Wick
IF INSIDEBAR THEN
Drawrectangle(BarIndex - 4,H5,BarIndex,L5)coloured(255,255,250,30)BORDERCOLOR(255,255,250,130)
endif
IF TWOUP THEN
Drawrectangle(BarIndex - 4,H5,BarIndex,L5)coloured(0,200,250,30)BORDERCOLOR(0,200,250,130)
endif
/////////////////////////////////////////////////////////////////////////////////////////
IF TWODOWN THEN
Drawrectangle(BarIndex - 4,H5,BarIndex,L5)coloured(255,0,0,30)BORDERCOLOR(255,0,0,100)
endif
IF OUTSIDEBAR THEN
Drawrectangle(BarIndex - 4,H5,BarIndex,L5)coloured(255,0,250,30)BORDERCOLOR(255,0,250,100)
endif
ENDIF
Return