软件名称:[B]分时主图加日K线(主图 源码 贴图)[/B]
软件类型:国产软件
运行环境:Win9X/Win2000/WinXP/Win2003/
软件语言:简体中文
授权方式:免费版
软件大小:2.00 KB
官方主页:Home Page
更新时间:2011-12-27 04:11:07
软件简介:
{引用日线}
JC:C;
JO:O;
JH:H;
JL:L;
JC1:REF(C,1);
JO1:REF(O,1);
JH1:REF(H,1);
JL1:REF(L,1);
JC2:REF(C,2);
JO2:REF(O,2);
JH2:REF(H,2);
JL2:REF(L,2);
JC3:REF(C,3);
JC4:REF(C,4);
JC5:REF(C,5);
JCYC:=(HIGH+LOW+OPEN+2*CLOSE)/5;
明日阻力:=2*JCYC-LOW;
明日支撑:=2*JCYC-HIGH;
明日突破:=JCYC+(HIGH-LOW);
明日反转:=JCYC-(HIGH-LOW);
阻力:REF(明日阻力,1);
支撑:REF(明日支撑,1);
突破:REF(明日突破,1);
反转:REF(明日反转,1);
JM1:MA(C,5);
JM2:MA(C,10);
把以上代码保存为 引用日线 公式名作为主图的引用。
{主图公式)
INPUT: 上下调整(400,10,1000),左右调整(577,0,1000),打开关闭(3,0,3);
{日K线引用}
if 打开关闭>0 then begin
阻力:="引用日线.阻力#day";支撑:="引用日线.支撑#day";突破:="引用日线.突破#day";反转:="引用日线.反转#day";
JM1:="引用日线.JM1#day";JM2:="引用日线.JM2#day";
JC:="引用日线.JC#day";JO:="引用日线.JO#day";JH:="引用日线.JH#day";JL:="引用日线.JL#day";
JC1:="引用日线.JC1#day";JO1:="引用日线.JO1#day";JH1:="引用日线.JH1#day";JL1:="引用日线.JL1#day";
JC2:="引用日线.JC2#day";JO2:="引用日线.JO2#day";JH2:="引用日线.JH2#day";JL2:="引用日线.JL2#day";
JC3:="引用日线.JC3#day";
YT1:=JC>JC1 AND JC=JO;
YT2:=JC<=JC1 AND JC=JO;
YT3:=JC1>JC2 AND JC1=JO1;
YT4:=JC1<=JC2 AND JC1=JO1;
YT5:=JC2>JC3 AND JC2=JO2;
YT6:=JC2<=JC3 AND JC2=JO2;
{昨收阳}
JJCA1:=IF(ABS(JC1-JO1)>0.015,JC1/JO1*2000-2000,5);
JJHA1:=JH1/JC1*2000-2000;
JJLA1:=JO1/JL1*2000-2000;
JWA1:=JC1-JO1>0 OR YT3>0;
if JWA1>0 then begin
DRAWRECTREL(左右调整,上下调整-JJCA1,左右调整+17,上下调整,0),COLOR4535FF;
DRAWRECTREL(左右调整+8,上下调整-JJCA1-JJHA1,左右调整+9,上下调整-JJCA1,0),COLOR5040FF;
DRAWRECTREL(左右调整+8,上下调整,左右调整+9,上下调整+JJLA1,0),COLOR5040FF;
end;
JZST:=STRFIND(stkname,'S',1) AND JC1/JC2>=1.048;
JZTB:=JC1/JC2>=1.0994 OR JZST;
if JZTB>0 then begin
DRAWRECTREL(左右调整+2,上下调整-JJCA1+2,左右调整+15,上下调整-2,RGB(255,255,0)),COLORYELLOW;
end;
{昨收阴}
JJHA2:=JH1/JO1*2000-2000;
JJLA2:=JC1/JL1*2000-2000;
JWA2:=JO1-JC1>0 OR YT4>0;
if JWA2>0 then begin
DRAWRECTREL(左右调整,上下调整,左右调整+17,上下调整-JJCA1,RGB(0,255,255)),COLORFFFF00;
DRAWRECTREL(左右调整+8,上下调整-JJHA2,左右调整+9,上下调整-JJCA1,RGB(0,255,255)),COLORFFFF00;
DRAWRECTREL(左右调整+8,上下调整-JJCA1,左右调整+9,上下调整-JJCA1+JJLA2,RGB(0,255,255)),COLORFFFF00;
end;
JZST1:=STRFIND(stkname,'S',1) AND JC1/JC2<=0.953;
JZTB1:=JC1/JC2<=0.902 OR JZST1;
if JZTB1>0 then begin
DRAWRECTREL(左右调整+2,上下调整+2,左右调整+15,上下调整-JJCA1-2,RGB(255,255,255)),COLORFFFFFF;
end;
{前收阳}
JJCB1:=IF(ABS(JC2-JO2)>0.015,JC2/JO2*2000-2000,5);
JJHB1:=JH2/JC2*2000-2000;
JJLB1:=JO2/JL2*2000-2000;
JZKB1:=JO1/JC2*2000-2000;
QSYB1:=上下调整+JZKB1;
JWB1:=(JC2-JO2>0 OR YT5>0);
if JWB1>0 then begin
DRAWRECTREL(左右调整-23,QSYB1+JJCB1,左右调整-6,QSYB1,0),COLOR4535FF;
DRAWRECTREL(左右调整-15,QSYB1-JJHB1,左右调整-14,QSYB1,0),COLOR5040FF;
DRAWRECTREL(左右调整-15,QSYB1+JJCB1+JJLB1,左右调整-14,QSYB1+JJCB1,0),COLOR5040FF;
end;
JZST2:=STRFIND(stkname,'S',1) AND JC2/JC3>=1.048;
JZTB2:=JC2/JC3>=1.0994 OR JZST2;
if JZTB2>0 then begin
DRAWRECTREL(左右调整-21,QSYB1+JJCB1-2,左右调整-8,QSYB1+2,RGB(255,255,0)),COLORYELLOW;
end;
{前收阴}
JJHB2:=JH2/JO2*2000-2000;
JJLB2:=JC2/JL2*2000-2000;
JWB1:=(JO2-JC2>0 OR YT6>0);
if JWB1>0 then begin
DRAWRECTREL(左右调整-23,QSYB1+JJCB1,左右调整-6,QSYB1,RGB(0,255,255)),COLORFFFF00;
DRAWRECTREL(左右调整-15,QSYB1+JJCB1-JJHB2,左右调整-14,QSYB1+JJCB1,RGB(0,255,255)),COLORFFFF00;
DRAWRECTREL(左右调整-15,QSYB1,左右调整-14,QSYB1+JJLB2,RGB(0,255,255)),COLORFFFF00;
end;
JZST3:=STRFIND(stkname,'S',1) AND JC2/JC3<=0.953;
JZTB3:=JC2/JC3<=0.902 OR JZST3;
if JZTB3>0 then begin
DRAWRECTREL(左右调整-21,QSYB1+JJCB1+2,左右调整-8,QSYB1-2,RGB(255,255,255)),COLORFFFFFF;
end;
{今收阳}
JJCC1:=IF(ABS(JC-JO)>0.015,JC/JO*2000-2000,5);
JJHC1:=JH/JC*2000-2000;
JJLC1:=JO/JL*2000-2000;
JZKC1:=JO/JC1*2000-2000;
QSYC1:=上下调整-JJCA1-JZKC1;
JWC1:=(JC-JO>0 OR YT1>0);
if JWC1>0 then begin
DRAWRECTREL(左右调整+23,QSYC1-JJCC1,左右调整+40,QSYC1,0),COLOR4535FF;
DRAWRECTREL(左右调整+31,QSYC1-JJCC1-JJHC1,左右调整+32,QSYC1-JJCC1,0),COLOR5040FF;
DRAWRECTREL(左右调整+31,QSYC1,左右调整+32,QSYC1+JJLC1,0),COLOR5040FF;
end;
JZST4:=STRFIND(stkname,'S',1) AND JC/JC1>=1.048;
JZTB4:=JC/JC1>=1.0994 OR JZST4;
if JZTB4>0 then begin
DRAWRECTREL(左右调整+25,QSYC1-JJCC1+2,左右调整+38,QSYC1-2,RGB(255,255,0)),COLORYELLOW;
end;
{今收阴}
JJHC2:=JH/JO*2000-2000;
JJLC2:=JC/JL*2000-2000;
JWC2:=(JO-JC>0 OR YT2>0);
if JWC2>0 then begin
DRAWRECTREL(左右调整+23,QSYC1,左右调整+40,QSYC1-JJCC1,RGB(0,255,255)),COLORFFFF00;
DRAWRECTREL(左右调整+31,QSYC1-JJHC2,左右调整+32,QSYC1,RGB(0,255,255)),COLORFFFF00;
DRAWRECTREL(左右调整+31,QSYC1-JJCC1,左右调整+32,QSYC1-JJCC1+JJLC2,RGB(0,255,255)),COLORFFFF00;
end;
JZST5:=STRFIND(stkname,'S',1) AND JC/JC1<=0.953;
JZTB5:=JC/JC1<=0.902 OR JZST5;
if JZTB5>0 then begin
DRAWRECTREL(左右调整+25,QSYC1+2,左右调整+38,QSYC1-JJCC1-2,RGB(255,255,255)),COLORFFFFFF;
end;
JZLC1:=阻力/JO*2000-2000;
JZZC1:=支撑/JO*2000-2000;
JTPC1:=突破/JO*2000-2000;
JFZC1:=反转/JO*2000-2000;
JMAC1:=JM1/JO*2000-2000;
JMAC2:=JM2/JO*2000-2000;
if 打开关闭>2 then begin
DRAWTEXTREL(左右调整+38,QSYC1-JZLC1,'ˉˉˉ'),Colorffa800;
DRAWTEXTREL(左右调整+60,QSYC1-JZLC1,'阻力 '+NUMTOSTRN(阻力,2)),Colorffa800;
DRAWTEXTREL(左右调整+38,QSYC1-JZZC1,'ˉˉˉ'),Colorffa800;
DRAWTEXTREL(左右调整+60,QSYC1-JZZC1,'支撑 '+NUMTOSTRN(支撑,2)),Colorffa800;
DRAWTEXTREL(左右调整+38,QSYC1-JTPC1,'ˉˉˉ'),Colorffa800;
DRAWTEXTREL(左右调整+60,QSYC1-JTPC1,'突破 '+NUMTOSTRN(突破,2)),Colorffa800;
DRAWTEXTREL(左右调整+38,QSYC1-JFZC1,'ˉˉˉ'),Colorffa800;
DRAWTEXTREL(左右调整+60,QSYC1-JFZC1,'反转 '+NUMTOSTRN(反转,2)),Colorffa800;
end;
if 打开关闭>1 then begin
DRAWTEXTREL(左右调整+20,QSYC1-JMAC1,'ˉˉˉˉˉˉˉ'),ColorFFFFFF;
DRAWTEXTREL(左右调整+120,QSYC1-JMAC1,'MA5 '+NUMTOSTRN(JM1,2)),ColorFFFFFF;
DRAWTEXTREL(左右调整+20,QSYC1-JMAC2,'ˉˉˉˉˉˉˉˉˉˉ'),COLORYELLOW;
DRAWTEXTREL(左右调整+140,QSYC1-JMAC2,'MA10 '+NUMTOSTRN(JM2,2)),COLORYELLOW;
end;end;
上图中上下调整 左右调整 就是调整日K线的位置,打开关闭设置为:3 是全部打开,2是只开日K线和5 10 日均线,1是只开日K线,0是全部关闭。
[url=http://www.70822.com/soft/sort013/sort03/down-42547.html]分时主图加日K线(主图 源码 贴图)[/url]