GGGcsjdj 发表于 2024-4-22 17:12:06

求指导一下报警滞后一根线


      Alma12   = iAlma(iMA(NULL,适应周期,1,0,MODE_SMA,AlmaPrice,i),AlmaPeriod+22,AlmaSigma,AlmaSample,rates_total,i);
      Almada12 = Almadb12 = EMPTY_VALUE;
      slope12= (i<rates_total-1) ? (Alma12>Alma12) ? 1 : (Alma12<Alma12) ? -1 : slope12 : 0;
      if (slope12==-1) PlotPoint(i,rates_total,Almada12,Almadb12,Alma12);
if (alertsOn)
   {
      int whichBar = 1; if (alertsOnCurrent) whichBar = 0;
      if (slope12 != slope12)
      {
         if (slope12 == 1) doAlert(" 涨");
         if (slope12 ==-1) doAlert("跌");      

m1800 发表于 2024-4-22 17:12:07

本帖最后由 m1800 于 2024-4-22 21:29 编辑

指标设置中,alertsOnCurrent   设置为0 的时候就当前K线位置报警,如果设置为1,则收线后,报警位置在上一根k线.

GGGcsjdj 发表于 2024-4-22 21:32:14

谢谢您,我是想要在往后一根,这个太灵敏,要信号确认

GGGcsjdj 发表于 2024-4-22 22:02:04

m1800 发表于 2024-4-22 17:12
指标设置中,alertsOnCurrent   设置为0 的时候就当前K线位置报警,如果设置为1,则收线后,报警位置在上一根k ...


谢谢您,我是想要在往后一根,这个太灵敏,要信号确认
页: [1]
查看完整版本: 求指导一下报警滞后一根线