//@version=3
study("Top Bottom ",overlay=true)
per=input(14)
loc= lowhighest(high ,per2) and high>=highest(high ,per2)
top=barssince(loc2)
/////BUY-SELL/////
buy=topbottom
sell=top>bottom and top bottom ? red :
na
bgcolor(color=background, transp=85)
//@version=3
study("Top Bottom ",overlay=true)
per=input(14)
loc= lowhighest(high ,per2) and high>=highest(high ,per2)
top=barssince(loc2)
/////BUY-SELL/////
buy=topbottom
sell=top>bottom and top bottom ? red :
na
bgcolor(color=background, transp=85)