//VK SLline V 1.01
// Low volume bar concept with Stoploss line
_SECTION_BEGIN("VKSLline V 1.01");
n=Day() != Ref(Day(), -1);
a=LowestSince(n,V);
hh=ValueWhen(V==a,H);
ll=ValueWhen(V==a,L);
hr = ValueWhen(V==a,Hour());
mn = ValueWhen(V==a,Minute());
e36 = EMA(C,36);
res=max(e36,hh);
sup=min(e36,ll);
avd=IIf(C>Ref(res,-1),1,IIf(C<Ref(sup,-1),-1,0));
avn=ValueWhen(avd!=0,avd,1);
tsl=IIf(avn==1,sup,res);
col = IIf(avn==1,colorBlue,colorRed);
buysg= avn==1;
sellsg= avn != 1;
buysg= ExRem(buysg,sellsg);
sellsg= ExRem(sellsg,buysg);
PlotShapes(IIf(buysg,shapeUpArrow,0),colorWhite,0,Graph0,-35,0);
PlotShapes(IIf(sellsg,shapedownArrow,0),colorskyBlue,0,Graph0,-45,0);
plot(tsl,"\nVKSL ",col,stylethick);
y=5;
PlotOHLC(y,Y+10,y,y,"",col,styleOwnScale|styleNoLabel|styleCloud,0,200,0,-5);
_SECTION_END();
Buy= buysg;
Sell = sellsg;
Filter = Buy OR Sell;