当前位置:→ 公式指标网 > 公式解答 > 正文 

    编写要求:

     

    www.gszx.com.cn网解答:

     网友求助:

    D 1 100 5
    F 1 100 10
    Y 1 100 60

    VAR1:=(CLOSE>REF(CLOSE,1) AND CLOSE>REF(CLOSE,2));
    VAR2:=(REF(VAR1,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR3:=(REF(VAR2,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR4:=(REF(VAR3,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR5:=(REF(VAR4,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR6:=(REF(VAR5,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR7:=(REF(VAR6,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR8:=(REF(VAR7,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR9:=(REF(VAR8,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VARA:=(REF(VAR9,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VARB:=(REF(VARA,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VARC:=(REF(VARB,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    红色:STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,3,0),COLOR0000AA;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,2.5,0),COLOR0000BB;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,2,0),COLOR0000CC;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,1.5,0),COLOR0000DD;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,1,0),COLOR0000EE;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,1,0),COLOR0000FF;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,1,0),COLOR0000FF;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,O,0.1,0),COLOR0000FF;
    STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,LOW,HIGH,0.1,0),COLOR0000FF;
    VARD:=(CLOSE<REF(CLOSE,1) AND CLOSE<REF(CLOSE,2));
    VARE:=(REF(VARD,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VARF:=(REF(VARE,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR10:=(REF(VARF,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR11:=(REF(VAR10,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR12:=(REF(VAR11,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR13:=(REF(VAR12,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR14:=(REF(VAR13,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR15:=(REF(VAR14,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR16:=(REF(VAR15,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    VAR17:=(REF(VAR16,1) AND CLOSE<=REF(CLOSE,1) AND CLOSE>=REF(CLOSE,2));
    VAR18:=(REF(VAR17,1) AND CLOSE>=REF(CLOSE,1) AND CLOSE<=REF(CLOSE,2));
    青色:STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,3,0),COLORAAAA00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,2.5,0),COLORBBBB00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,2,0),COLORCCCC00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,1.5,0),COLORDDDD00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,1,0),COLOREEEE00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,1,0),COLORFFFF00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,1,0),COLORFFFF00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,O,0.1,0),COLORFFFF00;
    STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,LOW,HIGH,0.1,0),COLORFFFF00;
    VAR19:=((REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1)) AND VAR1);
    黄色:STICKLINE(VAR19 AND "MACD.MACD">0,C,O,3,0),COLOR33AACC;
    STICKLINE(VAR19 AND "MACD.MACD">0,C,O,3,0),COLOR33BBCC;
    STICKLINE(VAR19 AND "MACD.MACD">0,C,O,2.5,0),COLOR33CCCC;
    STICKLINE(VAR19 AND "MACD.MACD">0,C,O,2,0),COLOR33DDCC;
    STICKLINE(VAR19 AND "MACD.MACD">0,C,O,1,0),COLOR33EECC;
    STICKLINE(VAR19 AND "MACD.MACD">0,C,O,1,0),COLOR33FFCC;
    STICKLINE(VAR19,LOW,HIGH,0.1,0),COLOR33FFCC;
    MA6:MA(CLOSE,D),COLORWHITE,LINETHICK1;
    MA18:MA(CLOSE,F),COLORYELLOW,LINETHICK1;
    MA55:MA(CLOSE,Y),COLORRED,LINETHICK2;
    {MA60:MA(CLOSE,60),COLORMAGENTA,LINETHICK2;
    上升势:IF("MACD.DEA">0,MA(CLOSE,M60),DRAWNULL),COLORRED,LINETHICK2;};
    HD:=FILTER(BACKSET(FILTER(REF(C,10)=HHV(C,2*10+1),10),10+1),10);
    LD:=FILTER(BACKSET(FILTER(REF(C,10)=LLV(C,2*10+1),10),10+1),10);
    波峰:IF(BARSLAST(HD)<BARSLAST(LD) AND NOT(HD),REF(C,BARSLAST(HD)),REF(C,BARSLAST(HD))),COLORFF00FF,POINTDOT;
    波谷:IF(BARSLAST(HD)>BARSLAST(LD) AND NOT(LD),REF(C,BARSLAST(LD)),REF(C,BARSLAST(LD))),COLOR80FF00,POINTDOT;
    突破:=CROSS(C,波峰) AND VOL>MA(VOL,25) AND C/REF(C,1)>1.0143;
    DRAWTEXT(突破,L*0.870,'突破'),COLORMAGENTA;
    DRAWICON(突破,L*0.97,1);
    M3:MA(CLOSE,3),COLORRED,LINETHICK;
    M13:MA(CLOSE,13),COLORRED,LINETHICK;
    M34:MA(CLOSE,34),COLORRED,LINETHICK;
    X:=BARSLAST(REF(CROSS(C,MA(C,120)),1)) AND CROSS(MA(C,20),MA(C,120));
    IF(M34<REF(M34,1),M34,DRAWNULL),COLORGREEN,LINETHICK;
    STICKLINE(M3>=M13 AND M34>=REF(M34,1) ,H ,L ,0.1 ,0 ),COLORRED;
    STICKLINE(M3>=M13 AND M34>=REF(M34,1) AND C>=O ,O ,C ,3 ,1 ),COLORRED;
    STICKLINE(M3>=M13 AND M34>=REF(M34,1) AND C<O ,O ,C ,3 ,0 ),COLORRED;
    STICKLINE(M3<M13 AND M34>=REF(M34,1) ,H ,L ,0.1 ,0 ),COLORYELLOW;
    STICKLINE(M3<M13 AND M34>=REF(M34,1) AND C>=O ,O ,C ,3 ,1 ),COLORYELLOW;
    STICKLINE(M3<M13 AND M34>=REF(M34,1) AND C<O ,O ,C ,3 ,0 ),COLORYELLOW;
    STICKLINE(M3<M13 AND M34<REF(M34,1) ,H ,L ,0.1 ,0 ),COLORGREEN;
    STICKLINE(M3<M13 AND M34<REF(M34,1) AND C>=O ,O ,C ,3 ,1 ),COLORGREEN;
    STICKLINE(M3<M13 AND M34<REF(M34,1) AND C<O ,O ,C ,3 ,0 ),COLORGREEN;
    STICKLINE(M3>=M13 AND M34<REF(M34,1) ,H ,L ,0.1 ,0 ),COLORMAGENTA;
    STICKLINE(M3>=M13 AND M34<REF(M34,1) AND C>=O ,O ,C ,3 ,1 ),COLORMAGENTA;
    STICKLINE(M3>=M13 AND M34<REF(M34,1) AND C<O ,O ,C ,3 ,0 ),COLORMAGENTA;
    {DRAWTEXT(X,MA(C,120)-0.13,'牛股'),COLORRED,LINETHICK3;};
    {老鼠仓}
    AA1:=AMOUNT/V;
    BB1:=L<AA1*0.9;
    CC1:=(C-REF(C,1))/REF(C,1)*100>1.2;
    DD1:=L<MA(C,5)*0.921;
    EE1:=V<MA(V,5)*1.5;
    FF1:=BB1 AND CC1 AND DD1 AND EE1;
    DRAWTEXT(FF1,(LOW* 0.97),'老鼠仓'),COLOR4080FF;
    DIF:=EMA(DCLOSE,12)-EMA(DCLOSE,26);
    DEA:=EMA(DIF,9);
    AAA:=(DIF-DEA)*2*60;
    起爆:=CROSS(AAA-REF(AAA,1),15),COLORRED,LINETHICK2;
    DRAWTEXT(起爆,L*0.99,'↖暴张'),COLORYELLOW,LINETHICK2;

     
    解答如下:
    注意有DCLOSE慎用
    DIF:=EMA(DCLOSE,12)-EMA(DCLOSE,26);
    DEA:=EMA(DIF,9);
    AAA:=(DIF-DEA)*2*60;
    起爆:CROSS(AAA-REF(AAA,1),15);

     

    互动内容:
    昵称: 验证码:验证码 

关于我们 - 联系我们 - 广告合作 - 下载声明 - 网站帮助 - 友情链接 - 网站地图 - RSS订阅 - TOP
Copyright © gszx.com.cn™,All Rights Reserved.ICP备案号:湘ICP备09016573号
股票公式,股票指标,股票软件,股票知识
股票公式,股票指标,股票软件,股票知识湘公网安备43108102000039号