您好,欢迎访问三七文档
当前位置:首页 > 金融/证券 > 股票报告 > 缠论中枢划线(笔和线段)主图指标公式-优化后
KU1:=IF(HIGH=HHV(HIGH,3),1,0);KD1:=IF(LOW=LLV(LOW,3),1,0);UL:=IF(REF(KU1,2)=1ANDREF(KU1,1)=0ANDKU1=0,REF(HIGH,2),REF(HIGH,2+BARSLAST(REF(KU1,2)=1ANDREF(KU1,1)=0ANDKU1=0)));DL:=IF(REF(KD1,2)=1ANDREF(KD1,1)=0ANDKD1=0,REF(LOW,2),REF(LOW,2+BARSLAST(REF(KD1,2)=1ANDREF(KD1,1)=0ANDKD1=0)));HV:=HULANDHREF(H,1);LV:=LDLANDLREF(L,1);GP:=BARSLAST(HV);DP:=BARSLAST(LV);IP:=IF(GP=0,DP,GP)3;HV1:=HVANDIPANDH=HHV(H,BARSLAST(LV));LV1:=LVANDIPANDL=LLV(L,BARSLAST(HV));DRAWLINE(LV1,LOW,HV1,HIGH,0),COLORYELLOW,LINETHICK2;DRAWLINE(HV1,HIGH,LV1,LOW,0),COLORMAGENTA,LINETHICK2;N1:=10;N2:=10;DISP:=2;K:=1;P1:=PEAK(1,K*N1,1);P2:=PEAK(1,K*N1,2);WP1:=PEAKBARS(1,K*N1,1);WP2:=PEAKBARS(1,K*N1,2);T1:=TROUGH(2,K*N2,1);T2:=TROUGH(2,K*N2,2);WT1:=TROUGHBARS(2,K*N2,1);WT2:=TROUGHBARS(2,K*N2,2);TJ1:=P1T1ANDP2T2;ZD:=MAX(T1,T2);ZG:=MIN(P1,P2);LL:=MIN(T1,T2);HH:=MAX(P1,P2);TJ2:=FILTER(ZGZD,2);TJ3:=ZG=REF(ZG,BARSLAST(TJ2))ORZD=REF(ZD,BARSLAST(TJ2));TJ4:=TJ1ANDTJ2ANDNOT(TJ3);TJ5:=BETWEEN(ZD,REF(ZD,REF(BARSLAST(TJ4),1)),REF(ZG,REF(BARSLAST(TJ4),1)));TJ6:=BETWEEN(ZG,REF(ZD,REF(BARSLAST(TJ4),1)),REF(ZG,REF(BARSLAST(TJ4),1)));TJ7:=ZGREF(ZG,REF(BARSLAST(TJ4),1))ANDZDREF(ZD,REF(BARSLAST(TJ4),1));TJ8:=TJ4ANDNOT(TJ5ORTJ6ORTJ7);ZSD:=IF(TJ8,ZD,REF(ZD,1));ZSG:=IF(TJ8,ZG,REF(ZG,1));ZSH:=IF(TJ8,HH,REF(HH,1));ZSL:=IF(TJ8,LL,REF(LL,1));STICKLINE(TJ8,ZSH,ZSL,0,-1);STICKLINE(TJ8,ZSD,ZSG,IF(DISP=1,3,0),1),COLORMAGENTA;DRAWTEXT(DISP=2,ZSH,''),COLORWHITE;中枢高:ZSG,COLORMAGENTA;IF(DISP=2,REF(ZSG,BARSLAST(TJ8)),DRAWNULL),CIRCLEDOT,COLORMAGENTA;中枢低:ZSD,COLORYELLOW;IF(DISP=2,REF(ZSD,BARSLAST(TJ8)),DRAWNULL),CIRCLEDOT,COLORYELLOW;中枢最高:ZSH,COLORRED;IF(DISP=2,REF(ZSH,BARSLAST(TJ8)),DRAWNULL),POINTDOT,COLORRED;中枢最低:ZSL,COLORGREEN;IF(DISP=2,REF(ZSL,BARSLAST(TJ8)),DRAWNULL),POINTDOT,COLORGREEN;MA5:MA(CLOSE,5),COLORFF00FF,LINETHICK1;命真好:=MA5REF(MA5,1);命真坏:=MA5REF(MA5,1);DRAWBAND(MA5,RGB(255,96,96),REF(MA5,1),RGB(0,224,224));
本文标题:缠论中枢划线(笔和线段)主图指标公式-优化后
链接地址:https://www.777doc.com/doc-4877690 .html