x:=(close-ref(close,1))/ref(close,1)*100;涨停:=x>9.94;{求助者自己定义的} 五十天之内:=if(currbarscount,c,draw**);x1:=const(ref(c,1));x2:=ref(llv(if((五十天之内)>x1 and 涨停,c,date),50),1);上穿:cross(c,x2)and 涨停;
涨2停:=c>=intpart(ref(c,1)*(1.0995)*100)/100 and c=h and currbarscount<=20; 涨停中处:=ref((h+l)/2,barslast(涨2停)); xg:cross(涨停中处*1.006,c) and not(涨2停) and c>涨停中处*0.995;