文章目录:
- 1、求大师分享,告诉我这个红绿背景主图是什么指标公式源码。那里可以下载?
- 2、通达信主图指标源码,求老师看有没有未来,并帮改成选股和预警公式,谢谢
- 3、通达信软件的主图和两个副图的指标源码改为条件选股公式
- 4、请老师帮忙编写下图主图指标公式,用在通达信版
- 5、找龙回头主图源码公式
求大师分享,告诉我这个红绿背景主图是什么指标公式源码。那里可以下载?
NA:=STRCAT(CON2STR(YEAR,0),' 年 ');
YA:=STRCAT(CON2STR(MONTH,0),' 月 ');
RA:=STRCAT(CON2STR(DAY,0),' 日 ');
SJ:=STRCAT(STRCAT(NA,YA), RA);
DRAWTEXT_FIX(C0,0.88,0,0,SJ);
{布林+宝塔+蓝灰操盘}
{蓝灰底}
买线:=EMA(C,2);
卖线:=EMA(SLOPE(C,21)*20+C,42);
STICKLINE(买线=卖线,HHV(H,60),LLV(L,60),5,0),COLOR000045;
STICKLINE(买线卖线,HHV(H,60),LLV(L,60),5,0),COLOR004500;
{红轨道}
红轨道:=MA(MA(CLOSE,3),1),LINETHICK1,COLORYELLOW;
轨道:MA(MA(CLOSE,3),3),COLOR32CD32,LINETHICK2;
SHENG:=IF(红轨道=轨道,轨道,DRAWNULL);
升:SHENG,COLORMAGENTA,LINETHICK2;
{变色K线}
N1:=14;
M:=6;
TR1:=EXPMEMA(MAX(MAX(HIGH-LOW,ABS(HIGH-REF(CLOSE,1))),ABS(REF(CLOSE,1)-LOW)),N1);
HD :=HIGH-REF(HIGH,1);
LD :=REF(LOW,1)-LOW;
DMP:=EXPMEMA(IF(HD0HDLD,HD,0),N1);
DMM:=EXPMEMA(IF(LD0LDHD,LD,0),N1);
PDI:=DMP*100/TR1,LINETHICK2;
MDI:=DMM*100/TR1;
ADX:=EXPMEMA(ABS(MDI-PDI)/(MDI+PDI)*100,M);
ADXR:=EXPMEMA(ADX,M);
VAR1:=CLOSEREF(CLOSE,1) AND CLOSEREF(CLOSE,2);
VAR2:=REF(VAR1,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR3:=REF(VAR2,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR4:=REF(VAR3,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR5:=REF(VAR4,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR6:=REF(VAR5,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR7:=REF(VAR6,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR8:=REF(VAR7,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR9:=REF(VAR8,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VARA:=REF(VAR9,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VARB:=REF(VARA,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VARC:=REF(VARB,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
STICKLINE(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),3,1),COLOR0000FF;
VARD:=CLOSEREF(CLOSE,1) AND CLOSEREF(CLOSE,2);
VARE:=REF(VARD,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VARF:=REF(VARE,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR10:=REF(VARF,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR11:=REF(VAR10,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR12:=REF(VAR11,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR13:=REF(VAR12,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR14:=REF(VAR13,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR15:=REF(VAR14,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR16:=REF(VAR15,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR17:=REF(VAR16,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
VAR18:=REF(VAR17,1) AND CLOSE=REF(CLOSE,1) AND CLOSE=REF(CLOSE,2);
STICKLINE(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,CLOSE,REF(CLOSE,1),3,0),COLORC08000;
VAR19:=REF(VARD OR VARE OR VARF OR VAR10 OR VAR11 OR VAR12 OR VAR13 OR VAR14 OR VAR15 OR VAR16 OR VAR17 OR VAR18,1) AND VAR1;
STICKLINE(VAR19,REF(CLOSE,1),REF(CLOSE,2),3,0),COLORMAGENTA ;
VAR1A:=REF(VAR1 OR VAR2 OR VAR3 OR VAR4 OR VAR5 OR VAR6 OR VAR7 OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,1) AND VARD;
STICKLINE(VAR1A,REF(CLOSE,1),REF(CLOSE,2),3,0) ,COLOR00FF00; }
{箱体线}
N:=7;
T1:=CONST(LLVBARS(LOW,N));
T1HIGH:=CONST(REF(HIGH,T1));
CC:=CONST(CURRBARSCOUNT);
T2:=CONST(BARSLAST((CURRBARSCOUNT (CC+T1)) AND (HIGHT1HIGH)));
T2HIGH:=CONST(REF(HIGH,T2));
T3:=CONST(BARSLAST((CURRBARSCOUNT (CC+T2)) AND (HIGHT2HIGH)));
T3HIGH:=CONST(REF(HIGH,T3));
突破杀入线:DRAWLINE(CURRBARSCOUNT=T3+1, T3HIGH, ISLASTBAR, T3HIGH, 1),LINETHICK1,COLORYELLOW;
DRAWTEXT(ISLASTBAR, T3HIGH, '杀入线!'),LINETHICK1,COLORYELLOW;
AB:=EMA(((2*C+H+L)/4-LLV(LOW,30))/(HHV(HIGH,30)-LLV(LOW,30))*100,8);
BA:=EMA(AB,5);
A1{高}:=REFDATE(REF(HHV(H,96),5),DATE);
B1{低}:=REFDATE(REF(LLV(L,96),5),DATE);
DY{中}:=((A1)+(B1))/2;
箱顶:IF(AB0 AND AB-BA=0,A1,A1),COLORGREEN,DOTLINE;
箱腰:IF(AB0 AND AB-BA=0,DY,DY),COLORYELLOW,DOTLINE;
箱低:IF(AB0 AND AB-BA=0,B1,B1),COLORRED,DOTLINE;
DRAWTEXT(ISLASTBAR,箱顶,'箱顶'),COLORYELLOW;
DRAWTEXT(ISLASTBAR,箱腰,'箱腰'),COLORYELLOW;
DRAWTEXT(ISLASTBAR,箱低,'箱低'),COLORYELLOW;
VARAA:=IF(CLOSE150,91.3,0.913);
{突破:INTPART(CLOSE/VARAA )*VARAA,POINTDOT,LINETHICK4,COLORRED;
再突破:突破+VARAA,POINTDOT,LINETHICK4,COLOR00FF00 ;
回踩:(突破+再突破)/2,POINTDOT,COLORWHITE,LINETHICK4;}
STICKLINE(CROSS(ZIG(3,5),REF(ZIG(3,5),1)),箱低,箱腰,0.1,-1),COLORRED;
STICKLINE(CROSS(REF(ZIG(3,5),1),ZIG(3,5)),箱顶,箱腰,0.1,-1),COLORGREEN;
DRAWICON(CROSS(ZIG(3,5),REF(ZIG(3,5),1)),箱腰,1);
DRAWICON(CROSS(REF(ZIG(3,5),1),ZIG(3,5)),箱腰,2);
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.02,0.01,0,'K线底部出红色或粉色,可低吸建仓!'),COLORRED;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.02,0.05,0,'绿点表示长期的压力点!'),COLORGREEN;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.02,0.10,0,'白点表示中短期的压力和支撑点,'),COLORGREEN;
DRAWTEXT_FIX(CURRBARSCOUNT=1,0.02,0.16,0,'红点表示有效支撑或突破长中短期压力点!股价向下跌破,原则清仓!'),COLORGREEN;
EE:=(H+L+O+2*C)/5;
CRTP:=EE+(H-L);
CRZL:=2*EE-L;
CRZC:=2*EE-H;
CRFZ:=EE-(H-L);
高:CONST(CRTP),COLORRED;
阻:CONST(CRZL),COLORC7C9FF;
支:CONST(CRZC),COLOR7C9CFF;
反:CONST(CRFZ),COLORDD00DD;
DRAWTEXT(ISLASTBAR, 反, '反转价'),LINETHICK1,COLORDD00DD;
DRAWTEXT(ISLASTBAR, 支, '支撑'),LINETHICK1,COLOR7C9CFF;
DRAWTEXT(ISLASTBAR, 阻, '阻力'),LINETHICK1,COLORC7C9FF;
DRAWTEXT(ISLASTBAR, 高, ' 高破线'),LINETHICK1,COLORGREEN;
均线:=EXPMA(C,12),COLORGRAY,LINETHICK2;
日:=50;
昨前:=3;
高2:=REF(HHV(H,日),昨前);
低2:=REF(LLV(L,日),昨前);
H4:=高2-(高2-低2)*0.618;
H5:=高2-(高2-低2)*0.809;
支撑80.9%:REFDATE(H5,DATE),COLORRED;
支撑61.8%:REFDATE(H4,DATE),COLORGREEN,;
STICKLINE(CURRBARSCOUNT=1,支撑80.9%,支撑80.9%,300,-1),COLORGREEN;
STICKLINE(CURRBARSCOUNT=1,支撑61.8%,支撑61.8%,300,-1),COLORRED;
DRAWTEXT(CURRBARSCOUNT=1 AND 支撑80.9%,支撑80.9%,'备钱'),COLORGREEN;
DRAWTEXT(CURRBARSCOUNT=1 AND 支撑61.8%,支撑61.8%,'转运'),COLORRED;
WH1:=IF(L=LLV(L,9),L,0);
WH2:=CONST(BARSLAST(WH1!=0));
WH3:=CONST(IF(WH2=0,H,REF(H,WH2)));
WH4:=CONST(REF(BARSLAST(HWH3),WH2+1)+WH2+1);
WH5:=CONST(IF(WH4=0,H,REF(H,WH4)));
WH6:=CONST(REF(BARSLAST(HWH5),WH4+1)+WH4+1);
WH7:IF(CURRBARSCOUNT=WH2+10,CONST(IF(WH6=0,H,REF(H,WH6))),DRAWNULL),COLORRED,DOTLINE;
STICKLINE(CURRBARSCOUNT=WH2+1 AND L=LLV(L,9),O,C,3,0),COLORRED;
DRAWTEXT(CURRBARSCOUNT=WH2+10,WH7,'LINE'),COLORRED;
DRAWTEXT(ISLASTBAR,WH7,'进场'),COLORRED;
WH8:IF(CURRBARSCOUNT=WH2+1,IF(L=LLV(L,9),L,DRAWNULL),DRAWNULL),CIRCLEDOT;
H81:=IF(H=HHV(H,9),H,DRAWNULL);
H82:=CONST(BARSLAST(H81!=DRAWNULL));
H83:=CONST(IF(H82=0,L,REF(L,H82)));
H84:=CONST(REF(BARSLAST(LH83),H82+1)+H82+1);
H85:=CONST(IF(H84=0,L,REF(L,H84)));
H86:=CONST(REF(BARSLAST(LH85),H84+1)+H84+1);
H87:=IF(CURRBARSCOUNT=H82+10,CONST(IF(H86=0,L,REF(L,H86))),DRAWNULL),DOTLINE;
H88:=IF(CURRBARSCOUNT=H82+1,IF(H=HHV(H,9),H,DRAWNULL),DRAWNULL),CIRCLEDOT;
DRAWTEXT(CURRBARSCOUNT=H82+10,H87,'LINE'),COLORYELLOW;
DRAWTEXT(ISLASTBAR,H87,'止损'),COLORYELLOW;
DIF:=EMA(DCLOSE,12)-EMA(DCLOSE,26);
DEA:=EMA(DIF,9);
AAA:=(DIF-DEA)*2*60;
起爆:=CROSS(AAA-REF(AAA,1),15);
DRAWTEXT(起爆,MA(L,3),'↖暴张'),COLORYELLOW,LINETHICK2;
LC:=REF((O+H+L+2*C)/5,1);
{短线擒黑码}
RSI:=SMA(MAX(C-LC,0),7,1)/SMA(ABS(C-LC),7,1)*10;
TYP:=(HIGH+LOW+CLOSE)/3;
CCI:=(TYP-MA(TYP,23))/(0.015*AVEDEV(TYP,23));
买:=CROSS(RSI,7.1) AND MA(V,5)MA(V,10),COLORRED;
DRAWTEXT(CROSS(RSI,7.1) AND MA(V,5)MA(V,10),MA(L,3),'↖◆短线擒黑码◆'),COLORWHITE;
DRAWICON(买,MA(L,3),17);
卖:=CROSS(7.1,RSI) AND MA(V,10)MA(V,5),COLORGREEN;
DRAWTEXT(CROSS(7.1,RSI) AND MA(V,10)MA(V,5),箱顶,'■■逃跑■■'),COLORGREEN;
DRAWICON(卖,MA(H,3),28);
{绝密买点}
A81:=EMA(C,3),COLORWHITE;
A82:=EMA(C,5),COLORYELLOW;
A83:=EMA(C,7),COLORMAGENTA;
A84:=EMA(C,12),COLORGREEN;
A85:=EMA(C,20),COLORRED;
A86:=EMA(C,50),COLORBLUE,LINETHICK2;
SS8:=CROSS(A81,A85) AND CO AND CREF(C,1) AND C/REF(C,1)=1.018 ;
SSS8:=CROSS(A81,A85) AND CO AND CREF(C,1) AND C/REF(C,1)=1.018;
DRAWICON(SS8 ,MA(L,3),5);
DRAWTEXT(SS8,MA(L,3),'↖绝密买点'),COLORYELLOW;
ZYX1:="DMI.PDI"(12,6);
ZYX2:="DMI.MDI"(12,6);
ZYX3:=ZYX165 AND ZYX1REF(ZYX1,1);
ZYX4:=LLV(ZYX1,0);
ZYX5:=BARSLAST(ZYX4=ZYX1);
ZYX6:=(0-REF(ZYX2,4))/(ZYX4-REF(ZYX2,ZYX5))2;
ZYX7:=ZYX1REF(ZYX1,1);
ZYX8:=VOL2*MA(VOL,30);
ZYX9:="DMI.ADX"(12,6);
ZYXA:="DMI.ADXR"(12,6);
ZYXB:=CLOSEMA(CLOSE,30) AND CLOSEMA(CLOSE,30)*1.04;
ZYXC:=MA(CLOSE,30)REF(MA(CLOSE,30),1);
ZYXD:=BARSLAST(CROSS(MA(CLOSE,5),MA(CLOSE,10)))BARSLAST(CROSS(MA(CLOSE,10),MA(CLOSE,5)));
{ZYXE:=0-"MACD.DIFF"(7,21,3);}
ZYXF:=TROUGHBARS(3,15,1)4;
ZYX10:=EMA(CLOSE,30)REF(EMA(CLOSE,30),2);
ZYX11:=IF(ZYXF=1,50,0);
ZYX12:=CROSS(ZYX2,ZYX1) AND CROSS(ZYXA,ZYX9);
ZYX13:=CROSS(ZYX2,ZYX1) AND CROSS(ZYX9,ZYXA);
ZYX14:=ZYXB AND ZYXC AND ZYXD AND ZYX10 AND ZYX6 AND ZYX7 AND ZYX8*50;
ZYX15:=BARSLAST(CROSS(ZYX2,ZYX1)=1);
ZYX16:=BARSLAST(CROSS(ZYX1,ZYX2)=1);
ZYX17:=HHV(ZYX1,ZYX16);
ZYX18:=BARSLAST(ZYX1=ZYX17);
{STICKLINE(FILTER(ZYXF=1,5),50,0,10,0),COLORRED;}
ZYX19:=ZYX3 OR ZYX12 OR ZYX13*100;
ZYX1A:=ZYX13*100;
DRAWICON(FILTER(ZYXF=1,3),MA(L,3),23);
DRAWTEXT(FILTER(ZYXF=1,3),箱低,'■■铁底■■'),COLORGREEN;
{量能平台}
ND:=10;
PTD:=CONST(LLVBARS(V,ND));
TDPX:IF(CURRBARSCOUNT=ND,CONST(IF(PTD=0,O,REF(O,PTD))),DRAWNULL),COLORFF0000;
IF(CURRBARSCOUNT=PTD+1,TDPX,DRAWNULL),CIRCLEDOT,COLORFF0000,LINETHICK2;
DRAWTEXT(ISLASTBAR,TDPX,' 【地平线】'),COLORFF0000;
G21:=30;
T112:=CONST(HHVBARS(V,G21));
T122:=IF(CURRBARSCOUNT=G21+7,CONST(IF(T112=0,H,REF(H,T112))),DRAWNULL);
T122A:=IF(CURRBARSCOUNT=T112+1,T122,DRAWNULL),CIRCLEDOT,COLORWHITE;
DRAWTEXT(ISLASTBAR,T122,'30天量能平台'),COLORWHITE;
W10:=10;
TW1:=CONST(HHVBARS(V,W10));
TW0:=IF(CURRBARSCOUNT=W10+7,CONST(IF(TW1=0,C,REF(C,TW1))),DRAWNULL);
TW0A:=IF(CURRBARSCOUNT=TW1+1,TW0,DRAWNULL),CIRCLEDOT,COLORWHITE;
DRAWTEXT(ISLASTBAR,TW0,'10量能平台'),COLORWHITE;
W20:=20;
TW20:=CONST(HHVBARS(V,W20));
TW22:=IF(CURRBARSCOUNT=W20+7,CONST(IF(TW20=0,C,REF(C,TW20))),DRAWNULL);
TW22A:=IF(CURRBARSCOUNT=TW20+1,TW22,DRAWNULL),COLORWHITE;
DRAWTEXT(ISLASTBAR,TW22,'20量能平台'),COLORWHITE;
MW:=10;
MW1:=CONST(LLVBARS(V,MW));
MW0:=IF(CURRBARSCOUNT=MW+7,CONST(IF(MW1=0,O,REF(O,MW1))),DRAWNULL);
MW0A:=IF(CURRBARSCOUNT=MW1+1,MW0,DRAWNULL),CIRCLEDOT,COLORWHITE;
DRAWTEXT(ISLASTBAR,MW0,'地量反弹量能平台'),COLORWHITE;
{N1:=18;N2:=36;N3:=55;}
EM1:=EMA(C,18),NODRAW;
EM2:=EMA(C,36),COLORRED;
EM3:=EMA(C,55),COLORGREEN;
TJ8:=BETWEEN(EM2,EM1,EM3);
{DRAWICON(TJ8=0,L,14);}
B18:='-----------------财富平台';
DRAWTEXT(VOL=HHV(VOL,20),C ,B18),COLORRED;
{超跌反弹}
RSV:=(CLOSE-LLV(LOW,11))/(HHV(HIGH,11)-LLV(LOW,11))*100;
短期底部:=LLV(OPEN,30);
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
J:=(3*K-2*D),LINETHICK2;
D2:=SMA(J,3,1)*0.82;
通达信主图指标源码,求老师看有没有未来,并帮改成选股和预警公式,谢谢
(1)无未来函数
(2)选股公式如下(买入):
VAR1:=(100 - ((90 * (HHV(HIGH,14) - CLOSE)) / (HHV(HIGH,14) - LLV(LOW,14))));
VAR2:=(100 - ((90 * (HHV(HIGH,14) - CLOSE)) / (HHV(HIGH,14) - LLV(LOW,14))));
VAR3:=(100 - MA(((100 * (HHV(HIGH,6) - CLOSE)) / (HHV(HIGH,6) - LLV(LOW,6))),34));
DIR1:=ABS(CLOSE-REF(CLOSE,5));
VIR1:=SUM(ABS(CLOSE-REF(CLOSE,1)),5);
ER1:=DIR1/VIR1;
CS1:=ER1*(0.8-2/8)+2/8;
CQ1:=CS1*CS1;
DIR2:=ABS(CLOSE-REF(CLOSE,10));
VIR2:=SUM(ABS(CLOSE-REF(CLOSE,1)),10);
ER2:=DIR2/VIR2;
CS2:=ER2*(0.8-2/24)+2/24;
CQ2:=CS2*CS2;
CROSS(VAR2,MA(VAR3,6));
通达信软件的主图和两个副图的指标源码改为条件选股公式
第一个
JJ:=(CLOSE+HIGH+LOW)/3;
A:=EMA(JJ,5);
B:=REF(A,1);
XG:ABREF(A,1)REF(B,1);
第二个
RV:=(CLOSE-LLV(LOW,27))/(HHV(HIGH,27)-LLV(LOW,27))*100;
VAR4:=SMA(RV,3,1);
VAR5:=SMA(VAR4,3,1);
XG:CROSS(VAR4,VAR5) AND VAR530;
第三个
N:=21; M:=5;
TH:=SUM(IF(CLOSEREF(CLOSE,1),VOL,0),N);
TL:=SUM(IF(CLOSEREF(CLOSE,1),VOL,0),N);
TQ:=SUM(IF(CLOSE=REF(CLOSE,1),VOL,0),N);
VAR0:=100*(TH*2+TQ)/(TL*2+TQ);
VAR1:=MA(VAR0,M);
W:=CROSS(VAR0,VAR1);
WL1:=VAR1100;
WLT1:=W AND WL1;
TJ1:FILTER(WLT1,5);
请老师帮忙编写下图主图指标公式,用在通达信版
通达信专用机构通道主图指标公式
M1:=EMA(C,5);M2:=EMA(C,13);M3:=EMA(C,34);
MC1:=EMA(C,55);MC2:=EMA(C,89);MA4:=EMA(C,144);
判势线:=NEWSAR(1,100),COLORYELLOW,LINETHICK2;
牛熊线:IF(MC1MAX(MC2,MA4),MC1,IF(MC1MIN(MC2,MA4),MC2,MA4)),COLORFF00CC,LINETHICK2;
AA:=1;
中轨:EMA(CLOSE,17)*AA,LINETHICK1,COLORFFFFFF;
卖出线:中轨+2*STD(CLOSE,17),LINETHICK1,COLOR0000FF;
买入线:中轨-2*STD(CLOSE,17),LINETHICK1,COLOR00CC00;
清仓线:中轨+3*STD(CLOSE,17),LINETHICK1,COLORFF00FF;
满仓线:中轨-3*STD(CLOSE,17),LINETHICK1,COLOR00AA00;
LOCK:=IF(TIME1160101,1,0);
VARA:=MA(CLOSE,20);
趋势线:IF(VARAREF(VARA,2),VARA,IF(VARAREF(VARA,2),VARA,VARA)),COLOR00FF00;
IF(VARAREF(VARA,2),VARA,DRAWNULL),LINETHICK2,COLORFF00FF;
IF(VARA=REF(VARA,2),VARA,DRAWNULL),LINETHICK2,COLORFF0000;
IF(VARAREF(VARA,2),VARA,DRAWNULL),LINETHICK2,COLOR00FF00;
买入:IF(VARAREF(VARA,2) AND REF(VARA=REF(VARA,2),1),1,0),NODRAW,COLORAAAAAA;
DRAWICON(CROSS(LOW,满仓线),满仓线*0.96,11);
DRAWICON(CROSS(HIGH,清仓线),HIGH,12);
TY:=CLOSE;
A1:=REF(TY,10)=HHV(TY,2*10+1); B1:=FILTER(A1,10); C1:=BACKSET(B1,10+1); HD:=FILTER(C1,10);
A2:=REF(TY,10)=LLV(TY,2*10+1); B2:=FILTER(A2,10); C2:=BACKSET(B2,10+1); LD:=FILTER(C2,10);
A:=REF(CLOSE,BARSLAST(HD)); B:=REF(CLOSE,BARSLAST(LD));
T1:=BARSLAST(HD)BARSLAST(LD) AND NOT(HD) ;
T2:=BARSLAST(HD)BARSLAST(LD) AND NOT(LD);
波峰:IF(T1,A,A),COLORFF00FF,POINTDOT;
STICKLINE(T1,A,A,1.5,0),COLORFF00FF;
波谷:IF(T2,B,B),COLOR80FF00,POINTDOT;
STICKLINE(T2,B,B,1.5,0),COLOR80FF00;
MA1:=MA(C,3);
XG1:=MA1REF(MA1,1) AND REF(MA1,1)REF(MA1,2) AND CMA(C,7);
DRAWTEXT(FILTER(XG1,9),LOW*0.97,'B'),COLORRED,LINETHICK2;
DRAWICON(FILTER(XG1,9),LOW*0.98,1);
VAR2:=SUM(IF(CLOSEOPEN,VOL,0),30)/SUM(VOL,30)*100;
VAR3:=100-SUM(IF(CLOSEOPEN,VOL,0),30)/SUM(VOL,30)*100;
多头力量:= VAR2;
空头力量:= VAR3;
RSV:=(CLOSE-LLV(LOW,18))/(HHV(HIGH,18)-LLV(LOW,18))*100;
K:=SMA(RSV,3,1);
D:=SMA(K,3,1);
XG2:=多头力量 空头力量 AND 多头力量 - 空头力量30 AND CROSS(D,K) OR
MA1REF(MA1,1) AND REF(MA1,1)REF(MA1,2) AND REF(MA1,2)REF(MA1,3) AND K50;
DRAWTEXT(FILTER(XG2,9),H*1.06,'S'),COLORGREEN,LINETHICK2;
DRAWICON(FILTER(XG2,9),H*1.02,2);
{跳空缺口}
LL1:=REF(L,1);
HH1:=REF(H,1);
SQK:=LHH1;
XQK:=HLL1;
上跳:IF(SQK=1,L-HH1,DRAWNULL),COLORFF00FF,CROSSDOT,LINETHICK3,NODRAW;
下跳:IF(XQK=1,H-LL1,DRAWNULL),COLORGREEN,CROSSDOT,LINETHICK3,NODRAW;
STICKLINE(SQK,L,HH1,4*1,1),COLORYELLOW;{上跳}
STICKLINE(XQK,H,LL1,4*1,2),COLOR00FF00;{下跳}
DRAWTEXT(SQK,H,'上跳'),COLORYELLOW;
DRAWTEXT(XQK,L,'下跳'),COLOR00FF00;
{补缺口}
K1:=BARSLAST(LREF(H,1));
K2:=LREF(H,K1+1) AND COUNT(LREF(H,K1+1),K1)=1;
STICKLINE(K2,L,O,1,0),COLORFF00FF;{缺口回补};
DRAWTEXT(K2=1,L,'回补'),COLORFF00FF;
找龙回头主图源码公式
公式指标来源于网络.不知道是不是你要的.
{龙回头--主图指标}
MA1:MA(CLOSE,5);
MA2:MA(CLOSE,10);
MA3:MA(CLOSE,20);
MA4:MA(CLOSE,30);
MA5:MA(CLOSE,60);
强势线:MA(C,25)+MA(C,25)*20/100,LINETHICK2,COLORRED;
DM1:=C/REF(C,1)1.09 AND C=O;
DM2:=REF(C,4)REF(O,4) AND REF(C,4)/REF(C,5)0.96 AND REF(C,2)/REF(C,3)1.02 AND REF(C,1)/REF(C,2)1.02;
DM3:=MAX(REF(C,1),REF(O,1))/MIN(REF(C,1),REF(O,1))1.036 AND MAX(REF(C,2),REF(O,2))/MIN(REF(C,2),REF(O,2))1.036
AND MAX(REF(C,3),REF(O,3))/MIN(REF(C,3),REF(O,3))1.036;
DXGM:=COUNT(REF(DM1,1),10) AND DM2 AND DM3;
AM1:=C/REF(C,1)1.09 AND C=O;
AM2:=REF(C,3)REF(O,3) AND REF(C,3)/REF(C,4)0.96 AND REF(C,2)/REF(C,3)1.02 AND REF(C,1)/REF(C,2)1.02;
AM3:=MAX(REF(C,1),REF(O,1))/MIN(REF(C,1),REF(O,1))1.036 AND MAX(REF(C,2),REF(O,2))/MIN(REF(C,2),REF(O,2))1.036;
AXGM:=COUNT(REF(AM1,1),10) AND AM2 AND AM3;
BM1:=C/REF(C,1)1.09 AND C=O;
BM2:=REF(C,2)REF(O,2) AND REF(C,2)/REF(C,3)0.96;
BM3:=MAX(REF(C,1),REF(O,1))/MIN(REF(C,1),REF(O,1))1.05;
BXGM:=COUNT(REF(BM1,1),10) AND BM2 AND BM3;
CM1:=C/REF(C,1)1.09 AND C=O;
CM2:=REF(C,1)REF(O,1) AND REF(C,1)/REF(C,2)0.96;
CXGM:=COUNT(REF(CM1,1),10) AND CM2;
SGX:=MA(C,25)+MA(C,25)*20/100;
GYTJ1:=(BETWEEN(O/MA(C,10),1.02,0.99) OR BETWEEN(L/MA(C,10),1.04,0.99) OR (BETWEEN(L/SGX,1.01,0.995) AND SGX/MA(C,10)1.08))AND CMA(C,10)
AND BETWEEN(C/REF(C,1),1.05,0.97) AND MA(C,5)MA(C,10) AND MA(C,5)/MA(C,10)1.01 AND H/MAX(C,O)1.04
AND CMA(C,120)AND MA(C,20)MA(C,60) AND MA(C,20)MA(C,120) AND REF(L,1)/REF(MA(C,10),1)0.998;
GYTJ2:=REF(C,1)REF(MA(C,5),1) AND OMA(C,5) AND MA(C,10)MA(C,20) AND MA(C,20)MA(C,30);
ABXG:=(DXGM OR AXGM OR BXGM OR CXGM) AND GYTJ1 AND GYTJ2;
DRAWICON(ABXG,L*0.98,11);
DRAWTEXT(ABXG,L*0.94,'龙回头'),COLORWHITE;
SCMXG:=COUNT(ABXG,5) AND CROSS(MA(C,10),MA(C,5));
DRAWICON(SCMXG,L*0.98,9);
DRAWTEXT(SCMXG,L*0.94,'二次尾买'),COLORYELLOW;
OR VAR8 OR VAR9 OR VARA OR VARB OR VARC,CLOSE,REF(CLOSE,1),3,1),COLOR0000FF;VARD:=CLOSEREF(CLOSE,1) AND CLOSEREF(CLOSE,2);VARE:=REF(VARD,1) AND CLOSE
X:=EXPMEMA(ABS(MDI-PDI)/(MDI+PDI)*100,M);ADXR:=EXPMEMA(ADX,M);VAR1:=CLOSEREF(CLOSE,
C,2),REF(O,2))/MIN(REF(C,2),REF(O,2))1.036AND MAX(REF(C,3),REF(O,3))/MIN(REF(C,3),REF(