大智慧 画线主图指标公式
画线主图源码
MA7:MA(C,7);
MA14:MA(C,14),COLORyellow;
MA25:MA(C,25),LINETHICK1,COLORgreen;
MA50:MA(C,50),LINETHICK2,Color008364;
MA200:MA(C,200),LINETHICK1,ColorBLUE;
STICKLINE(C/REF(C,1)>=1.097,OPEN ,CLOSE ,3 ,0 ),coloryellow;
VAR0:="LTFUNC4@FORLT2";
VAR1:="LTFUNC4@LT_S1";
VAR2:="LTFUNC4@LT_HS";
VAR3:="LTFUNC4@LT_LS";
VAR4:="LTFUNC4@LT_P1";
VAR5:="LTFUNC4@LT_UPP";
VAR6:="LTFUNC4@LT_UDD";
VAR7:=EMA(ABS("DDX.DDX"),60);
VAR8:=MAX("DDX.DDX"/VAR7 + 7.5,7.5);
VAR9:=MIN("DDX.DDX"/VAR7,10);
VAR10:=IF(VAR1=0,VAR2,VAR3);
DRAWBMP(VAR4=1 AND REF(VAR4,1)=0,LOW,'buy1.bmp'),ALIGN1;
DRAWBMP(VAR4=0 AND REF(VAR4,1)=1,HIGH,'sell1.bmp'),ALIGN1,VALIGN2;
DRAWBMP(VAR1=1 AND REF(VAR1,1)=0 AND VAR4 + REF(VAR4,1) <> 1,LOW,'bs.bmp'),ALIGN1;
DRAWBMP(VAR1=0 AND REF(VAR1,1)=1 AND VAR4 + REF(VAR4,1) <> 1,HIGH,'ss.bmp'),ALIGN1,VALIGN2;
VAR11:=20;
VAR12:=REF(HIGH,4)=HHV(HIGH,2 * 4 + 1);
VAR13:=FILTER(VAR12,4);
VAR14:=BACKSET(VAR13,4 + 1);
VAR15:=FILTER(VAR14,4);
VAR16:=VAR15 OR BARSTATUS=2;
VAR17:=REF(LOW,4)=LLV(LOW,2 * 4 + 1);
VAR18:=FILTER(VAR17,4);
VAR19:=BACKSET(VAR18,4 + 1);
VAR20:=FILTER(VAR19,4);
VAR21:=VAR20 AND NOT(VAR15);
VAR22:=BACKSET(VAR16,REF(BARSLAST(VAR21),1) + 1);
VAR23:=VAR22 > REF(VAR22,1);
VAR24:=BACKSET(VAR23,2);
VAR25:=VAR24 > REF(VAR24,1);
VAR26:=BACKSET(VAR25 AND COUNT(VAR16,REF(BARSLAST(VAR21),1) + 2)=0,REF(BARSLAST(VAR21),1) + 2);
VAR27:=VAR26 > REF(VAR26,1);
VAR28:=BACKSET(VAR27 AND COUNT(VAR16,REF(BARSLAST(VAR21),1) + 2)=0,REF(BARSLAST(VAR21),1) + 2);
VAR29:=VAR28 > REF(VAR28,1);
VAR30:=IF(VAR16,COUNT(VAR21,REF(BARSLAST(VAR16),1) + 1),0);
VAR31:=IF(VAR30=1 AND VAR16,BARSLAST(VAR25),0);
VAR32:=IF(VAR16 AND REF(LOW,BARSLAST(VAR25)) >= REF(LOW,BARSLAST(VAR27)),BARSLAST(VAR27),BARSLAST(VAR25));
VAR33:=IF(VAR30=2 AND VAR16,VAR32,0);
VAR34:=IF(VAR30 >= 3 AND VAR16,IF(VAR16 AND REF(LOW,VAR32) >= REF(LOW,BARSLAST(VAR29)),BARSLAST(VAR29),VAR32),0);
VAR35:=VAR31 + VAR33 + VAR34;
VAR36:=BACKSET(VAR16,VAR35);
VAR37:=VAR36 > REF(VAR36,1);
VAR38:=BACKSET(VAR37,2);
VAR39:=VAR38 > REF(VAR38,1);
VAR40:=VAR39 OR BARSTATUS=2;
VAR41:=BACKSET(VAR40,REF(BARSLAST(VAR16),1) + 1);
VAR42:=VAR41 > REF(VAR41,1);
VAR43:=BACKSET(VAR42,2);
VAR44:=VAR43 > REF(VAR43,1);
VAR45:=BACKSET(VAR44 AND COUNT(VAR40,REF(BARSLAST(VAR16),1) + 2)=0,REF(BARSLAST(VAR16),1) + 2);
VAR46:=VAR45 > REF(VAR45,1);
VAR47:=BACKSET(VAR46 AND COUNT(VAR40,REF(BARSLAST(VAR16),1) + 2)=0,REF(BARSLAST(VAR16),1) + 2);
VAR48:=VAR47 > REF(VAR47,1);
VAR49:=IF(VAR40,COUNT(VAR15,REF(BARSLAST(VAR40),1) + 1),0);
VAR50:=IF(VAR49=1 AND VAR40,BARSLAST(VAR44),0);
VAR51:=IF(VAR40 AND REF(HIGH,BARSLAST(VAR44)) <= REF(HIGH,BARSLAST(VAR46)),BARSLAST(VAR46),BARSLAST(VAR44));
VAR52:=IF(VAR49=2 AND VAR40,VAR51,0);
VAR53:=IF(VAR49 >= 3 AND VAR40,IF(VAR40 AND REF(HIGH,VAR51) <= REF(HIGH,BARSLAST(VAR48)),BARSLAST(VAR48),VAR51),0);
VAR54:=VAR50 + VAR52 + VAR53;
VAR55:=BACKSET(VAR40,VAR54);
VAR56:=VAR55 > REF(VAR55,1);
VAR57:=BACKSET(VAR56,2);
VAR58:=VAR57 > REF(VAR57,1);
VAR59:=BACKSET(BARSTATUS=2,BARSLAST(VAR39) + 1);
VAR60:=VAR59 > REF(VAR59,1);
VAR61:=BACKSET(VAR60,REF(BARSLAST(VAR39),1) + 2);
VAR62:=VAR61 > REF(VAR61,1);
VAR63:=BACKSET(BARSTATUS=2,BARSLAST(VAR58) + 1);
VAR64:=VAR63 > REF(VAR63,1);
VAR65:=BACKSET(VAR64,REF(BARSLAST(VAR58),1) + 2);
VAR66:=VAR65 > REF(VAR65,1);
H1:IF(1,REF(HIGH,BARSLAST(VAR64)),CLOSE),PRECIS2,POINTDOT,COLOR99FF66;
VAR67:=IF(1,REF(HHV(CLOSE,8),BARSLAST(VAR64)),CLOSE);
H2:IF(1,REF(HIGH,BARSLAST(VAR66)),CLOSE),PRECIS2,POINTDOT,COLOR99FF66;
VAR68:=IF(1,REF(HHV(CLOSE,8),BARSLAST(VAR66)),CLOSE);
L1:IF(1,REF(LOW,BARSLAST(VAR60)),CLOSE),PRECIS2,POINTDOT,COLORFF66FF;
L2:IF(1,REF(LOW,BARSLAST(VAR62)),CLOSE),PRECIS2,POINTDOT,COLORFF66FF;
VAR69:=MIN(IF(1,REF(HIGH,BARSLAST(VAR64)),CLOSE),IF(1,REF(HIGH,BARSLAST(VAR66)),CLOSE));
VAR70:=REF(HIGH,3)=HHV(HIGH,2 * 3 + 1);
VAR71:=FILTER(VAR70,3);
VAR72:=BACKSET(VAR71,3 + 1);
VAR73:=FILTER(VAR72,3);
VAR74:=VAR73 OR BARSTATUS=2;
VAR75:=REF(LOW,3)=LLV(LOW,2 * 3 + 1);
VAR76:=FILTER(VAR75,3);
VAR77:=BACKSET(VAR76,3 + 1);
VAR78:=FILTER(VAR77,3);
VAR79:=VAR78 AND NOT(VAR73);
VAR80:=BACKSET(VAR74,REF(BARSLAST(VAR79),1) + 1);
VAR81:=VAR80 > REF(VAR80,1);
VAR82:=BACKSET(VAR81,2);
VAR83:=VAR82 > REF(VAR82,1);
VAR84:=BACKSET(VAR83 AND COUNT(VAR74,REF(BARSLAST(VAR79),1) + 2)=0,REF(BARSLAST(VAR79),1) + 2);
VAR85:=VAR84 > REF(VAR84,1);
VAR86:=BACKSET(VAR85 AND COUNT(VAR74,REF(BARSLAST(VAR79),1) + 2)=0,REF(BARSLAST(VAR79),1) + 2);
VAR87:=VAR86 > REF(VAR86,1);
VAR88:=IF(VAR74,COUNT(VAR79,REF(BARSLAST(VAR74),1) + 1),0);
VAR89:=IF(VAR88=1 AND VAR74,BARSLAST(VAR83),0);
VAR90:=IF(VAR74 AND REF(LOW,BARSLAST(VAR83)) >= REF(LOW,BARSLAST(VAR85)),BARSLAST(VAR85),BARSLAST(VAR83));
VAR91:=IF(VAR88=2 AND VAR74,VAR90,0);
VAR92:=IF(VAR88 >= 3 AND VAR74,IF(VAR74 AND REF(LOW,VAR90) >= REF(LOW,BARSLAST(VAR87)),BARSLAST(VAR87),VAR90),0);
VAR93:=VAR89 + VAR91 + VAR92;
VAR94:=BACKSET(VAR74,VAR93);
VAR95:=VAR94 > REF(VAR94,1);
VAR96:=BACKSET(VAR95,2);
VAR97:=VAR96 > REF(VAR96,1);
VAR98:=VAR97 OR BARSTATUS=2;
VAR99:=BACKSET(VAR98,REF(BARSLAST(VAR74),1) + 1);
VAR100:=VAR99 > REF(VAR99,1);
VAR101:=BACKSET(VAR100,2);
VAR102:=VAR101 > REF(VAR101,1);
VAR103:=BACKSET(VAR102 AND COUNT(VAR98,REF(BARSLAST(VAR74),1) + 2)=0,REF(BARSLAST(VAR74),1) + 2);
VAR104:=VAR103 > REF(VAR103,1);
VAR105:=BACKSET(VAR104 AND COUNT(VAR98,REF(BARSLAST(VAR74),1) + 2)=0,REF(BARSLAST(VAR74),1) + 2);
VAR106:=VAR105 > REF(VAR105,1);
VAR107:=IF(VAR98,COUNT(VAR73,REF(BARSLAST(VAR98),1) + 1),0);
VAR108:=IF(VAR107=1 AND VAR98,BARSLAST(VAR102),0);
VAR109:=IF(VAR98 AND REF(HIGH,BARSLAST(VAR102)) <= REF(HIGH,BARSLAST(VAR104)),BARSLAST(VAR104),BARSLAST(VAR102));
VAR110:=IF(VAR107=2 AND VAR98,VAR109,0);
VAR111:=IF(VAR107 >= 3 AND VAR98,IF(VAR98 AND REF(HIGH,VAR109) <= REF(HIGH,BARSLAST(VAR106)),BARSLAST(VAR106),VAR109),0);
VAR112:=VAR108 + VAR110 + VAR111;
VAR113:=BACKSET(VAR98,VAR112);
VAR114:=VAR113 > REF(VAR113,1);
VAR115:=BACKSET(VAR114,2);
VAR116:=VAR115 > REF(VAR115,1);
VAR117:=BACKSET(BARSTATUS=2,BARSLAST(VAR97) + 1);
VAR118:=VAR117 > REF(VAR117,1);
VAR119:=BACKSET(VAR118,REF(BARSLAST(VAR97),1) + 2);
VAR120:=VAR119 > REF(VAR119,1);
VAR121:=BACKSET(BARSTATUS=2,BARSLAST(VAR116) + 1);
VAR122:=VAR121 > REF(VAR121,1);
VAR123:=BACKSET(VAR122,REF(BARSLAST(VAR116),1) + 2);
VAR124:=VAR123 > REF(VAR123,1);
DRAWLINE(VAR120 AND 1,LOW,VAR118,LOW,1),COLORWHITE;
DRAWLINE(VAR124 AND 1,HIGH,VAR122,HIGH,1),COLORWHITE;
DRAWLINE(VAR66 AND 1,HIGH,VAR64,HIGH,1),LINETHICK2,COLORYELLOW;
DRAWLINE(VAR62 AND 1,LOW,VAR60,LOW,1),LINETHICK2,COLORYELLOW;
VAR125:=HHV(CLOSE,3);
VAR126:=HHV(CLOSE,19);
PARTLINE(VAR126,VAR125=VAR126 AND VAR126=REF(VAR126,1) AND 1,RGB(255,0,0)),LINETHICK2,COLORRED;
托:IF(1,REF(CLOSE,BARSLAST(VOL=HHV(VOL,26))),DATE),PRECIS2,POINTDOT,COLORYELLOW;
颈线:STICKLINE(VAR69,VAR69,VAR69,9,3),LINETHICK2,PRECIS2,COLORWHITE;
VAR127:=BARSLAST(REF(ZIG(3,19),1) < REF(ZIG(3,19),2));
VAR128:=BARSLAST(ZIG(3,19) > REF(ZIG(3,19),1));
DRAWTEXT(VAR127=2 AND 1,LOW * 0.98,'3'),COLORRED;
DRAWTEXT(VAR127=4 AND 1,HIGH * 1.02,'5'),COLOR9966FF;
DRAWTEXT(VAR127=7 AND 1,LOW * 0.98,'8'),COLORYELLOW;
DRAWTEXT(VAR127=12 AND 1,HIGH * 1.02,'13'),COLORFF33FF;
DRAWTEXT(VAR127=20 AND 1,LOW * 0.98,'21'),COLOR0066FF;
DRAWTEXT(VAR127=33 AND 1,HIGH * 1.02,'34'),COLORCYAN;
DRAWTEXT(VAR127=54 AND 1,LOW * 0.98,'55'),COLOR006600;
DRAWTEXT(VAR127=88 AND 1,HIGH * 1.02,'89'),COLORGREEN;
DRAWTEXT(VAR127=143 AND 1,LOW * 0.98,'144'),COLORCCFFFF;
DRAWTEXT(VAR128=3 AND 1,LOW * 0.98,'3'),COLORRED;
DRAWTEXT(VAR128=5 AND 1,HIGH * 1.02,'5'),COLOR9966FF;
DRAWTEXT(VAR128=8 AND 1,LOW * 0.98,'8'),COLORYELLOW;
DRAWTEXT(VAR128=13 AND 1,HIGH * 1.02,'13'),COLORFF33FF;
DRAWTEXT(VAR128=21 AND 1,LOW * 0.98,'21'),COLOR0066FF;
DRAWTEXT(VAR128=34 AND 1,HIGH * 1.02,'34'),COLORCYAN;
DRAWTEXT(VAR128=55 AND 1,LOW * 0.98,'55'),COLOR006600;
DRAWTEXT(VAR128=89 AND 1,HIGH * 1.02,'89'),COLORGREEN;
DRAWTEXT(VAR128=144 AND 1,LOW * 0.98,'144'),COLORCCFFFF;
STICKLINE(VAR128=1,OPEN,CLOSE,7,0),COLORGREEN;
STICKLINE(VAR128 < 1 AND REF(VAR128 > 1,1),OPEN,CLOSE,7,0),COLORYELLOW;
zg8:=FINANCE2(35);{总股}
lta8:=FINANCE2(36);{流通A}
sy8:=FINANCE2(3);{收益}
sl8:=DYNAINFO(39);{市盈率}
wf8:=FINANCE2(8);{未分}
gj8:=FINANCE2(7);{公积};
jz8:=FINANCE2(4);{净资}
cw8:='总股:'+zg8+' 流通A:'+lta8+' 收益:'+sy8+' 市盈率:'+sl8+' 未分:'+wf8+' 公积:'+gj8+' 净资:'+jz8;
DRAWTEXTREL(10,60,cw8),COLORGREEN;
DRAWTEXTREL(1,10,'■所属板块:'+BKNAME),COLORyellow;
DRAWTEXTREL(1,100,'■概念:'+SELFSTRING('概念')),COLORRED;
DRAWTEXTREL(1,160,'■主题投资:'+SELFSTRING('主题投资')),COLOR006EFF;
DRAWTEXTREL(1,200,'■流通盘 :'+CAPITAL/1000000+'亿股'),COLORFF00FF;