您现在的位置:程序化交易>> 期货公式>> 金字塔等>> 金字塔知识>>正文内容

有请老师帮把指标改成模型 [金字塔]

  • 咨询内容:

    {主趋势线:EMA(EMA(C,10),10),COLORBLUE,LINETHICK3;
    B:=主趋势线<REF(主趋势线,1);
    IF(B-1,主趋势线,DRAWNULL)COLORRED,LINETHICK3;}
    主趋势线:EMA(EMA(C,10),10),COLORRED,LINETHICK3;
    B:=主趋势线>REF(主趋势线,1);
    IF(B-1,主趋势线,DRAWNULL)COLORBLUE,LINETHICK3;

    AA:=EMA(C,5) > EMA(C,20);
    BB:=EMA(C,5) < EMA(C,20);
    CC:= EMA(C,5) > EMA(C,10);
    CC1:=EMA(C,5) < EMA(C,10);
    DD:=CLOSE<OPEN;


    STICKLINE(AA,H,L,0,0),COLORRED;
    STICKLINE(AA,O,C,3,1),COLORRED;
    STICKLINE(AA AND DD,O,C,3,0),COLORRED;
    STICKLINE(BB,H,L,0,0),COLORGREEN;
    STICKLINE(BB,O,C,3,1),COLORGREEN;

    STICKLINE(BB AND DD,O,C,3,0),COLORGREEN;
    STICKLINE(BB AND CC,H,L,0,1),COLORWHITE;
    STICKLINE(BB AND CC,O,C,3,1),COLORWHITE;
    STICKLINE(BB AND CC AND DD,O,C,3,0),COLORWHITE;
    STICKLINE(AA AND CC1,H,L,0,0),COLORWHITE;
    STICKLINE(AA AND CC1,O,C,3,1),COLORWHITE;
    STICKLINE(AA AND CC1 AND DD,O,C,3,0),COLORWHITE;


    AAA:=CONST(HHV(H,90));
    {DRAWTEXT(T1=1 AND CURRBARSCOUNT=58,AAA,'智能分析:目前处于红色买区,上涨趋势良好,多单持有。'),COLORRED,LINETHICK4;};
    DRAWTEXT(C AND CURRBARSCOUNT=80 ,AAA, '红色K线做多,绿色K线做空,白色K线平仓观望。 '),COLORYELLOW;

     

    红色K线开多,绿色K线开空,白色K线平仓,谢谢!

     

  • 金字塔客服:

    {B:=主趋势线<REF(主趋势线,1);
    IF(B-1,主趋势线,DRAWNULL)COLORRED,LINETHICK3;}
    主趋势线:EMA(EMA(C,10),10),COLORRED,LINETHICK3;
    B:=主趋势线>REF(主趋势线,1);
    IF(B-1,主趋势线,DRAWNULL)COLORBLUE,LINETHICK3;

    AA:=EMA(C,5) > EMA(C,20);
    BB:=EMA(C,5) < EMA(C,20);
    CC:= EMA(C,5) > EMA(C,10);
    CC1:=EMA(C,5) < EMA(C,10);
    DD:=CLOSE<OPEN;


    STICKLINE(AA,H,L,0,0),COLORRED;
    STICKLINE(AA,O,C,3,1),COLORRED;
    STICKLINE(AA AND DD,O,C,3,0),COLORRED;
    STICKLINE(BB,H,L,0,0),COLORGREEN;
    STICKLINE(BB,O,C,3,1),COLORGREEN;
    STICKLINE(BB AND DD,O,C,3,0),COLORGREEN;

    STICKLINE(BB AND CC,H,L,0,1),COLORWHITE;
    STICKLINE(BB AND CC,O,C,3,1),COLORWHITE;
    STICKLINE(BB AND CC AND DD,O,C,3,0),COLORWHITE;
    STICKLINE(AA AND CC1,H,L,0,0),COLORWHITE;
    STICKLINE(AA AND CC1,O,C,3,1),COLORWHITE;
    STICKLINE(AA AND CC1 AND DD,O,C,3,0),COLORWHITE;


    //AAA:=CONST(HHV(H,90));

    {红色K线开多,绿色K线开空}
    if aa then buy(holding=0,1,market);
    if bb  then buyshort(holding=0,1,market);
    if bb and cc  then sell(1,0,market);
    if aa and cc1  then sellshort(1,0,market);

     

  • 用户回复:

    有些条件重复了,我又改了一下

     

    {B:=主趋势线<REF(主趋势线,1);
    IF(B-1,主趋势线,DRAWNULL)COLORRED,LINETHICK3;}
    主趋势线:EMA(EMA(C,10),10),COLORRED,LINETHICK3;
    B:=主趋势线>REF(主趋势线,1);
    IF(B-1,主趋势线,DRAWNULL)COLORBLUE,LINETHICK3;

    AA:=EMA(C,5) > EMA(C,20);
    BB:=EMA(C,5) < EMA(C,20);
    CC:= EMA(C,5) > EMA(C,10);
    CC1:=EMA(C,5) < EMA(C,10);
    DD:=CLOSE<OPEN;


    STICKLINE(AA,H,L,0,0),COLORRED;
    STICKLINE(AA,O,C,3,1),COLORRED;
    STICKLINE(AA AND DD,O,C,3,0),COLORRED;
    STICKLINE(BB,H,L,0,0),COLORGREEN;
    STICKLINE(BB,O,C,3,1),COLORGREEN;
    STICKLINE(BB AND DD,O,C,3,0),COLORGREEN;

    STICKLINE(BB AND CC,H,L,0,1),COLORWHITE;
    STICKLINE(BB AND CC,O,C,3,1),COLORWHITE;
    STICKLINE(BB AND CC AND DD,O,C,3,0),COLORWHITE;
    STICKLINE(AA AND CC1,H,L,0,0),COLORWHITE;
    STICKLINE(AA AND CC1,O,C,3,1),COLORWHITE;
    STICKLINE(AA AND CC1 AND DD,O,C,3,0),COLORWHITE;


    //AAA:=CONST(HHV(H,90));

    {红色K线开多,绿色K线开空}
    if aa and not(cc1) then buy(holding=0,1,market);
    if bb and not(cc)  then buyshort(holding=0,1,market);
    if bb and cc  then sellshort(1,0,market);
    if aa and cc1  then sell(1,0,market);

     

  • 网友回复: 非常感谢

     

  • 网友回复: 老师,测试了一下,发现很多信号不对啊,麻烦再帮修改下,还有把画图的去掉,只留信号.

 

有思路,想编写各种指标公式,程序化交易模型,选股公式,预警公式的朋友

可联系技术人员 QQ: 1145508240  点击这里给我发消息进行 有偿 编写!不贵!点击查看价格!


【字体: 】【打印文章】【查看评论

相关文章

    没有相关内容