2013年12月26日 星期四

開盤前十五分鐘最低價被更新超過五次且跌幅尚未超過2%


if barfreq <> "Tick" then RaiseRuntimeError("請設定頻率為TICK");
variable:BarNumberOfToday(0); if Date <> Date[1] then  BarNumberOfToday=1 else  BarNumberOfToday+=1;{記錄今天的Bar}

if Date =currentdate  then begin

  variable: Point(0),idx(0),tTime(0);tTime=0;
  Point = intportion( BarNumberOfToday/10);
   for idx = 0 to 9
   begin
      if  Close[idx*Point] < Close[(idx+1)*Point] then  tTime+=1; {下跌時記1}
   end; 
  
   if tTime >=5 and{一路向下過低5}
      Timediff(Time,Time[BarNumberOfToday-1],"M") < 15{分鐘} and {離開盤第1個價15分鐘內}
      q_PriceChangeRatio > -2 {跌幅仍在2%}
   then   ret=1;
  

end;





沒有留言:

張貼留言