设为首页收藏本站

 找回密码
 注册
查看: 1893|回复: 0

请问pubu指标该如何编写 [复制链接]

Rank: 1

精华
0
UID
244422
积分
4
帖子
2
主题
2
阅读权限
10
注册时间
2016-12-10
最后登录
2017-3-7
发表于 2016-12-13 10:27:11 |显示全部楼层
我想问下TB中pubu指标该如何编写,Params
        Numeric Length1(4);
        Numeric Length2(6);
        Numeric Length3(9);
        Numeric Length4(13);
        Numeric Length3(18);
        Numeric Length4(24);
Vars
        Numeric short1;
        Numeric short2;
        Numeric media1;
        Numeric media2;
        Numeric long1;
        Numeric long2;
Begin
        short1=(xaverage(CLOSE,4)+average(CLOSE,8)+average(CLOSE,16))/3;
        short2=(xaverage(CLOSE,6)+average(CLOSE,12)+average(CLOSE,24))/3;
        media1=(xaverage(CLOSE,9)+average(CLOSE,18)+average(CLOSE,36))/3;
        media2=(xaverage(CLOSE,13)+average(CLOSE,26)+average(CLOSE,52))/3;  
        long1=(xaverage(CLOSE,18)+average(CLOSE,36)+average(CLOSE,72))/3;
        long2=(xaverage(CLOSE,24)+average(CLOSE,48)+average(CLOSE,96))/3;
        PlotNumeric("short1",short1,0,white);
        PlotNumeric("short2",short2,0,yellow);
        PlotNumeric("media1",media1,0,Magenta);
        PlotNumeric("media2",media2,0,Green);
        PlotNumeric("long1",long1,0,LightGray);
        PlotNumeric("long2",long2,0,Red);
End


这样子编写好像是错误的,求教大侠
您需要登录后才可以回帖 登录 | 注册

bottom

静态版|手机版|联系我们|交易开拓者 ( 粤ICP备07044698   

GMT+8, 2024-3-28 22:36

Powered by Discuz! X2 LicensedChrome插件扩展

© 2011-2012 交易开拓者 Inc.

回顶部