分析家公式网,提供指标公式,股票软件 用户登录  |  用户 注册

软件名称:[B]K线同图显示日周的主图指标 源码,贴图,主图[/B]
软件类型:国产软件
运行环境:Win9X/Win2000/WinXP/Win2003/
软件语言:简体中文
授权方式:免费版
软件大小:1.00 KB
官方主页:Home Page
更新时间:2012-05-20 04:08:14
软件简介:

看到十字军旗老师发了个日周月、多日K线组合指标,感觉非常不错,我也转发一个类似的指标---K线同图显示日周的主图指标,看盘很方便

DRAWGBK(1,COLORRGB(20,20,110),COLORRGB(0,0,50),1);
TBS:=POW(10,ABS(LOG(MINDIFF)));
//月线
BY:=MONTH;YB:=BY-REF(BY,1)<>0 OR BARPOS=1;
w:BARSLAST(YB),LINETHICK;
dg:=w=0 or ISLASTBAR;
wx:=0*C;
for P=datacount-1 downto lbound(dg) do
  if dg[P] then
    wx[P]:=0;
  else
    wx[P]:=wx[P+1]+1;
r:=BACKSET(ISLASTBAR,w+1)-ISLASTBAR;
wx:=refx(wx,1)+r,LINETHICK;
oo:=ref(o,w);
hh:=hhv(h,w+1);
LL:=LLv(L,w+1);
月开:ROUND(OO*TBS)/TBS,LINETHICK;
月高:ROUND(refx(hh,wx)*TBS)/TBS,LINETHICK;
月低:ROUND(refx(LL,wx)*TBS)/TBS,LINETHICK;
月收:ROUND(refx(c,wx)*TBS)/TBS,LINETHICK;
f:=月收>月开 or (月收=月开 and 月收>ref(月收,W));
j:=cross(w,wx);
STICKLINE(w>=0 and f AND NOT(BY<>REF(BY,1) OR BY<>REFX(BY,1)),月低,月高,20,0),COLORMAGENTA;
STICKLINE(w>=0 and not(f) AND NOT(BY<>REF(BY,1) OR BY<>REFX(BY,1)),月低,月高,20,0)COLORFFDD00;{}
P:=BARPOS;
DRAWTEXT(w>0  and   j,月高*1.01,'月'),COLOR00CCFF,ALIGN1;
DRAWNUMBER(w>0  and j,月高*1.01,BY,0),COLOR00CCFF,ALIGN2;
//
{周月K线}
//周线
BZ:=WEEKDAY;ZB:=DATEDIFF(REF(DATE,1),DATE)<>BZ-REF(BZ,1) OR BARPOS=1;
ZW:=BARSLAST(ZB),LINETHICK;
Zdg:=ZW=0 or ISLASTBAR;
Zwx:=0*c;
for P=datacount-1 downto lbound(Zdg) do
  if Zdg[P] then
    Zwx[P]:=0;
  else
    Zwx[P]:=Zwx[P+1]+1;
Zr:=BACKSET(ISLASTBAR,Zw+1)-ISLASTBAR;
Zwx:=refx(Zwx,1)+Zr,LINETHICK;
zq:=BARSLAST(ref(Zwx,1)=0 or BARPOS=1)+1;
Zo:=ref(o,Zw);
Zh:=hhv(h,Zw+1);
ZL:=LLv(L,Zw+1);
周开:ROUND(ZO*TBS)/TBS,LINETHICK;
周高:ROUND(refx(Zh,Zwx)*TBS)/TBS,,COLORFF,LINETHICK;
周低:ROUND(refx(ZL,Zwx)*TBS)/TBS,COLORFF00,LINETHICK;
周收:ROUND(refx(c,Zwx)*TBS)/TBS,,COLORFF00FF,LINETHICK;
ZF:=周收>周开 or (周收=周开 and 周收>ref(周收,Zw+1));
Zj:=cross(Zw,Zwx);
yt:=if(zq=1 and refx(zq,2)=1,13,if(refx(zq,1)=1 or zq=1,7,14));
//影线
STICKLINE(Zw>0 and ZF and Zj,周低,周高,1,0)COLORAAAAEE;
STICKLINE(周开<周收,周开,周收,YT,0),COLORAAAAEE;
STICKLINE(Zw>0 and not(ZF) and Zj,周低,周高,1,0)COLOREEAAAA;
STICKLINE(周开>周收,周开,周收,YT,0),COLOREEAAAA;
//日线
TJ:=CLOSE>OPEN or CLOSE=OPEN and CLOSE>REF(CLOSE,1);
STICKLINE(TJ,LOW,HIGH,1,0),ColorE9;
STICKLINE(TJ,LOW,CLOSE,8,0),Color80;
STICKLINE(TJ,LOW,CLOSE,6,0),ColorA5;
STICKLINE(TJ,LOW,CLOSE,4,0),ColorC0;
STICKLINE(TJ,LOW,CLOSE,2,0),ColorE6;
STICKLINE(NOT(TJ),HIGH,LOW,1,0),ColorAA00;
STICKLINE(NOT(TJ),CLOSE,OPEN,8,0),Color5000;
STICKLINE(NOT(TJ),CLOSE,OPEN,6,0),Color6600;
STICKLINE(NOT(TJ),CLOSE,OPEN,4,0),Color8000;
STICKLINE(NOT(TJ),CLOSE,OPEN,2,0),ColorA000;


[url=http://www.70822.com/soft/sort013/sort02/down-48879.html]K线同图显示日周的主图指标 源码,贴图,主图[/url]

关于本站 | 网站帮助 | 广告合作 | 声明 | 友情连接 | 网站地图 |
分析家公式网声明:本站所有股票公式软件资料均网上公开收集,如侵权请联系删帖。站内所有广告,均与本站无关!
Copyright © 2003-2024 70822.Com. All Rights Reserved .
页面执行时间:78.12500 毫秒