Advertisement
JustUncleL

Highest and lowest

Dec 30th, 2016
114
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.27 KB | None | 0 0
  1. //@version=2
  2. study(title='Function Highest/Lowest', overlay=true)
  3. src = input(close)
  4. length = input(10)
  5.  
  6.  
  7. h = highestbars(src, length)
  8. l = lowestbars(src, length)
  9. bcolor = h==0? yellow : l==0? black : na
  10.  
  11. barcolor(bcolor,title="Highest or lowest in Bar group")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement