MID:MA(CLOSE,20);//求N个周期的收盘价均线,称为布林通道中轨
TMP2:=STD(CLOSE,20);//求M个周期内的收盘价的标准差
TOP:MID+2*TMP2;//布林通道上轨
BOTTOM:MID-2*TMP2;//布林通道下轨
时间条件:=TIME>0430&&TIME<0705;
SY:=REF(H,1)-MAX(REF(O,1),REF(C,1));//上影长度
XY:=MIN(REF(O,1),REF(C,1))- REF(L,1);//下影长度
ST:=ABS(REF(O,1)-REF(C,1));
NOT(时间条件)&&(REF(H,1)>=REF(TOP,1)|| ((REF(H,1)>=(REF(TOP,1)-Q*MINPRICE)&&REF(H,1)<=REF(TOP,1)&&(REF(TOP,1)-REF(BOTTOM,1))>P*MINPRICE)))&& SY>=ST*N&&XY<=M*MINPRICE,SK;
SKVOL>0&&C<=BOTTOM,BP;
HH:=REF(H,BARSSK+1),NODRAW;
SKVOL>0&&C>=HH,BP;
NOT(时间条件)&&(REF(L,1)<=REF(BOTTOM,1)|| ((REF(L,1)<=(REF(BOTTOM,1)+Q*MINPRICE)&&REF(L,1)>=REF(BOTTOM,1)&&(REF(TOP,1)-REF(BOTTOM,1))>P*MINPRICE)))&& XY>=ST*N&&SY<=M*MINPRICE,BK;
BKVOL>0&&C>=TOP,SP;
LL:=REF(L,BARSBK+1),NODRAW;
BKVOL>0&&C<=LL,SP;
TIME=0500,CLOSEOUT;
CHECKSIG(BK,'A',0,'C',0,0);
CHECKSIG(SK,'A',0,'C',0,0);
CHECKSIG(SP,'A',0,'C',0,0);
CHECKSIG(BP,'A',0,'C',0,0);
SETALLSIGPRICETYPE(LIMIT_ORDER);
TIME>=0430,CLOSEOUT;
AUTOFILTER;
//比如1,在布林线上轨出现上影线长度是实体长度的N倍或N倍以上,下影线在M个点位以内,下根K线卖出,止损上影线最高点,止盈是布林线下轨
//PS:上影线可以是突破上轨或者触碰到上轨或者与上轨道接近10个点位以内,但如果是在接近上轨道Q个点位开仓的情况下是在上下轨距离P个点位以上
//2,在布林线下轨出现下影线长度是实体长度的N倍或N倍以上,上影线在M个点位以内,下跟K线买入,止损下影线最低点,止盈是布林线上轨
//PS:下影线可以是突破下轨或者触碰到下轨或者与下轨道接近10个点位以内,但如果是在接近下轨道Q个点位开仓的情况下是在上下轨距离P个点位以上