最新公告
  • 欢迎您光临九毛八公式指标网www.9m8.cn,本站全新改版试运行,期间内容全部免费,欢迎下载!欢迎加入本站VIP
  • UP系列___K线五法主图指标公式

    正文概述    2024-04-14 15:39:36  

    K线五法主图

    UP软件源码:

    影响时长:=60;

    实体涨跌幅:=(MAX(CLOSE,OPEN)/MIN(CLOSE,OPEN)-1)*100,nodraw;

    标志性K线:IFF(实体涨跌幅==HHV(实体涨跌幅,影响时长),1,0),nodraw,COLORYELLOW;

    影响时间:=barslast(标志性K线)+1,nodraw;

    上轨:IFF(BETWEEN(影响时间,1,影响时长),REF(HIGH,影响时间-1),DRAWNULL),NODRAW,COLORRED;

    下轨:IFF(BETWEEN(影响时间,1,影响时长),REF(LOW ,影响时间-1),DRAWNULL),NODRAW,COLORGREEN;

    冗余过滤:=BETWEEN(影响时间,2,59),NODRAW;

    STICKLINE(上轨,上轨,上轨,12,0),COLORRED;

    STICKLINE(下轨,下轨,下轨,12,0),COLORGREEN;

    STICKLINE3D(标志性K线 AND CLOSE>OPEN,CLOSE,OPEN,8,0),COLORRED;

    STICKLINE3D(标志性K线 AND CLOSE

    A_1:=CROSS(C,上轨) AND REF(CLOSE,影响时间-1)>REF(OPEN,影响时间-1);

    A_2:=COUNT(A_1,影响时间)==1 AND A_1;

    一飞冲天:IFF(A_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORRED;

    STICKLINE(一飞冲天,CLOSE,OPEN,8,0),COLORRED;

    STICKLINE(一飞冲天,HIGH,LOW,0,0),COLORRED;

    DRAWTEXT(一飞冲天,LOW,'B'),COLORRED;

    B_1:=CROSS(CLOSE,上轨) AND REF(CLOSE,影响时间-1)>REF(OPEN,影响时间-1);

    B_2:=COUNT(B_1,影响时间)==2 AND B_1;

    回首惊天:IFF(B_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORYELLOW;

    STICKLINE(回首惊天,CLOSE,OPEN,8,0),COLORYELLOW;

    STICKLINE(回首惊天,HIGH,LOW,0,0),COLORYELLOW;

    DRAWTEXT(回首惊天,LOW,'B'),COLORYELLOW;

    C_1:=CROSS(CLOSE,下轨) AND REF(CLOSE,影响时间-1)>REF(OPEN,影响时间-1) AND COUNT(回首惊天,影响时间)==0;

    C_2:=COUNT(C_1,影响时间)==1 AND C_1;

    蓄势擎天:IFF(C_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORMagenta;

    STICKLINE(蓄势擎天,CLOSE,OPEN,8,0),COLORMagenta;

    STICKLINE(蓄势擎天,HIGH,LOW,0,0),COLORMagenta;

    DRAWTEXT(蓄势擎天,LOW,'B'),COLORMagenta;

    D_1:=CROSS(下轨,CLOSE) AND REF(CLOSE,影响时间-1)

    D_2:=COUNT(D_1,影响时间)==1 AND D_1;

    飞流直下:IFF(D_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORGREEN;

    STICKLINE(飞流直下,CLOSE,OPEN,8,0),COLORGREEN;

    STICKLINE(飞流直下,HIGH,LOW,0,0),COLORGREEN;

    DRAWTEXT(飞流直下,HIGH*1.01,'S'),COLORGREEN;

    E_1:=CROSS(下轨,CLOSE) AND REF(CLOSE,影响时间-1)

    E_2:=COUNT(E_1,影响时间)==2 AND E_1;

    回首再下:IFF(E_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORWHITE;

    STICKLINE(回首再下,CLOSE,OPEN,8,0),COLORWHITE;

    STICKLINE(回首再下,HIGH,LOW,0,0),COLORWHITE;

    DRAWTEXT(回首再下,high*1.01,'S'),COLORWHITE; 

     

     

    修改为通达信的源码是:

    K线五法主图


    影响时长:=60;

    实体涨跌幅:=(MAX(CLOSE,OPEN)/MIN(CLOSE,OPEN)-1)*100,NODRAW;

    标志性K线:IFF(实体涨跌幅==HHV(实体涨跌幅,影响时长),1,0),NODRAW,COLORYELLOW;

    影响时间:=BARSLAST(标志性K线)+1,NODRAW;

    上轨:IFF(BETWEEN(影响时间,1,影响时长),REF(HIGH,影响时间-1),DRAWNULL),NODRAW,COLORRED;

    下轨:IFF(BETWEEN(影响时间,1,影响时长),REF(LOW ,影响时间-1),DRAWNULL),NODRAW,COLORGREEN;

    冗余过滤:=BETWEEN(影响时间,2,59),NODRAW;

    STICKLINE(上轨,上轨,上轨,12,0),COLORRED;

    STICKLINE(下轨,下轨,下轨,12,0),COLORGREEN;

    STICKLINE(标志性K线 AND CLOSE>OPEN,CLOSE,OPEN,8,0),COLORRED;

    STICKLINE(标志性K线 AND CLOSE

    A_1:=CROSS(C,上轨) AND REF(CLOSE,影响时间-1)>REF(OPEN,影响时间-1);

    A_2:=COUNT(A_1,影响时间)==1 AND A_1;

    一飞冲天:IFF(A_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORRED;

    STICKLINE(一飞冲天,CLOSE,OPEN,8,0),COLORRED;

    STICKLINE(一飞冲天,HIGH,LOW,0,0),COLORRED;

    DRAWTEXT(一飞冲天,LOW,'B'),COLORRED;

    B_1:=CROSS(CLOSE,上轨) AND REF(CLOSE,影响时间-1)>REF(OPEN,影响时间-1);

    B_2:=COUNT(B_1,影响时间)==2 AND B_1;

    回首惊天:IFF(B_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORYELLOW;

    STICKLINE(回首惊天,CLOSE,OPEN,8,0),COLORYELLOW;

    STICKLINE(回首惊天,HIGH,LOW,0,0),COLORYELLOW;

    DRAWTEXT(回首惊天,LOW,'B'),COLORYELLOW;

    C_1:=CROSS(CLOSE,下轨) AND REF(CLOSE,影响时间-1)>REF(OPEN,影响时间-1) AND COUNT(回首惊天,影响时间)==0;

    C_2:=COUNT(C_1,影响时间)==1 AND C_1;

    蓄势擎天:IFF(C_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORMAGENTA;

    STICKLINE(蓄势擎天,CLOSE,OPEN,8,0),COLORMAGENTA;

    STICKLINE(蓄势擎天,HIGH,LOW,0,0),COLORMAGENTA;

    DRAWTEXT(蓄势擎天,LOW,'B'),COLORMAGENTA;

    D_1:=CROSS(下轨,CLOSE) AND REF(CLOSE,影响时间-1)

    D_2:=COUNT(D_1,影响时间)==1 AND D_1;

    飞流直下:IFF(D_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORGREEN;

    STICKLINE(飞流直下,CLOSE,OPEN,8,0),COLORGREEN;

    STICKLINE(飞流直下,HIGH,LOW,0,0),COLORGREEN;

    DRAWTEXT(飞流直下,HIGH*1.01,'S'),COLORGREEN;

    E_1:=CROSS(下轨,CLOSE) AND REF(CLOSE,影响时间-1)

    E_2:=COUNT(E_1,影响时间)==2 AND E_1;

    回首再下:IFF(E_2 AND 影响时间!=1 AND 冗余过滤,1,DRAWNULL),NODRAW,COLORWHITE;

    STICKLINE(回首再下,CLOSE,OPEN,8,0),COLORWHITE;

    STICKLINE(回首再下,HIGH,LOW,0,0),COLORWHITE;

    DRAWTEXT(回首再下,HIGH*1.01,'S'),COLORWHITE; 


    九毛八公式指标,一个优质的公式指标平台!
    九毛八公式指标 » UP系列___K线五法主图指标公式 加入收藏