Help for Bollingar Band Scanner.

#1
Guys, I am trying to write a scanner to find stocks that have reached lower bollingar band with setting of bbandbot(C,200,2) on a 5 min chart.

below is the code That I have written which I think should work but for some reason when I scan nothing comes up in scanner, I'll appreciate if any body could guide me where I am going wrong.

_section_begin("Bollingar band scanner 5min")

timeframeset(in5minute);
a = (L<= (bbandbot(c,200,2))) AND ref(L,-1)>(ref(Bbandbot(c,200,2),-1));
timeframerestore();

filter = a;

addcolumn(a,"Bottom hit",colorblack,1.2);





that's it and no error is shown while saving but on scanning nothing comes up.
 
#2
Guys, I am trying to write a scanner to find stocks that have reached lower bollingar band with setting of bbandbot(C,200,2) on a 5 min chart.

below is the code That I have written which I think should work but for some reason when I scan nothing comes up in scanner, I'll appreciate if any body could guide me where I am going wrong.

_section_begin("Bollingar band scanner 5min")

timeframeset(in5minute);
a = (L<= (bbandbot(c,200,2))) AND ref(L,-1)>(ref(Bbandbot(c,200,2),-1));
timeframerestore();

filter = a;

addcolumn(a,"Bottom hit",colorblack,1.2);

that's it and no error is shown while saving but on scanning nothing comes up.
possible solutions
1) incase u are using a 1 min chart then calc will happen for 5 min time frame in case you are using a higher time frame chart the calc will not give correct results

2) best open a 5 min chart and remove the timeframe syntax and then test.

3) you might not have sufficient data to give results

4) no scrips are matching your condition
 

Similar threads