飞狐二指禅画线主图指标公式

[复制链接]
查看143 | 回复0 | 2021-8-21 11:30:19 | 显示全部楼层 |阅读模式

input:P(79,1,111),N(16,1,100);
VARA:=LLV(LOW,35);
VARB:=HHV(HIGH,30);
VARC:=(EMA((((CLOSE - VARA) / (VARB - VARA)) * 4),4) * 25);
DRAWICON(((VARC < 10) AND (((100 * (HHV(HIGH,14) - CLOSE)) / (HHV(HIGH,14) - LLV(LOW,14))) > 97)),(LOW * 0.98),1);
拐点:=MA(CLOSE,1);
拐点1:=MA(CLOSE,1);
GD1:=(REF((COUNT((拐点 <= REF(拐点,1)),5) = 5),1) AND (拐点 > REF(拐点,1)));
GD2:=(REF((COUNT((拐点1 <= REF(拐点1,1)),5) = 5),1) AND (拐点1 > REF(拐点1,1)));
AA:=(GD1 AND GD2);
DRAWICON(AA,(LOW * 0.99),1);
DRAWICON(AA,(LOW * 0.98),8);
V1:=((CLOSE + (4 * HIGH)) / 5);
V2:=LLV(V1,30);
生死线:(V2 * 0.98),LINETHICK1,colorFFB97A;
主线:=WMA(CLOSE,20);
主线2:WMA(CLOSE,N),LINETHICK0;
VAR1:=POW((CLOSE - 主线),1);
VAR2:=MA(VAR1,3);
VAR3:=SQRT(VAR2);
阻力线:=(主线 + (1.96 * VAR3));
支撑线:=(主线 - (1.96 * VAR3));
DRAWICON((主线2 > REF(主线2,1)),主线2,10);
PARTLINE(((主线2 > REF(主线2,1)) AND (阻力线 <> 支撑线)),主线2),LINETHICK0,colorFF;
临界线:=WMA(CLOSE,8);
VAR1:=POW((CLOSE - 临界线),1);
VAR2:=MA(VAR1,3);
VAR3:=SQRT(VAR2);
阻力线:=(临界线 + (1.96 * VAR3));
支撑线:=(临界线 - (1.96 * VAR3));
PARTLINE(((临界线 > REF(临界线,1)) AND (阻力线 <> 支撑线)),临界线),LINETHICK2,colorFF;
PARTLINE((临界线 < REF(临界线,1)),临界线),LINETHICK1,colorFF00;
PARTLINE((阻力线 = 支撑线),临界线),LINETHICK1,colorFF0000;
DRAWICON((CROSS(临界线,主线2) OR CROSS(临界线,0)),临界线,12),colorFF;
阻挡:=(SMA(HIGH,13,2) * 1.04);
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,9,0),colorFF5B00;
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,8,0),colorFF6C00;
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,7,0),colorFF7B00;
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,6,0),colorFF9C00;
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,5,0),colorFFBE00;
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,3.5,0),colorFFCC00;
STICKLINE((OPEN >= CLOSE),CLOSE,OPEN,1.5,0),colorFFFF00;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,8,0),colorAA;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,6,0),colorCC;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,4,0),colorDD;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,2,0),colorFF;
STICKLINE((CLOSE >= OPEN),HIGH,LOW,0,0),colorFFFF;
STICKLINE((CLOSE <= OPEN),CLOSE,OPEN,8,0),color998855;
STICKLINE((CLOSE <= OPEN),CLOSE,OPEN,6,0),colorBBAA77;
STICKLINE((CLOSE <= OPEN),CLOSE,OPEN,4,0),colorDDCC99;
STICKLINE((CLOSE <= OPEN),CLOSE,OPEN,2,0),colorFFEEBB;
STICKLINE((CLOSE <= OPEN),HIGH,LOW,0,0),colorFFFF00;
STICKLINE((CLOSE < OPEN),HIGH,LOW,1,0),color8800;
STICKLINE((CLOSE < OPEN),HIGH,LOW,0,0),colorFF00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,8,0),color8800;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,7,0),color9900;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,6,0),colorAA00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,5,0),colorBB00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,4,0),colorCC00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,3,0),colorDD00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,2,0),colorEE00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,1,0),colorFF00;
STICKLINE((CLOSE >= OPEN),HIGH,LOW,1,0),colorFF;
STICKLINE((CLOSE >= OPEN),HIGH,LOW,0,0),colorEEFF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,8,0),colorFF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,7,0),color22FF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,6,0),color44FF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,5,0),color66FF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,4,0),color88FF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,3,0),colorAAFF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,2,0),colorCCFF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,1,0),colorEEFF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,2,0),colorCCFF;
STICKLINE((CLOSE >= OPEN),CLOSE,OPEN,1,0),colorEEFF;
STICKLINE((CLOSE < OPEN),HIGH,LOW,1,0),color8800;
STICKLINE((CLOSE < OPEN),HIGH,LOW,0,0),colorFF00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,8,0),color8800;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,7,0),color9900;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,6,0),colorAA00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,5,0),colorBB00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,4,0),colorCC00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,3,0),colorDD00;
STICKLINE((CLOSE < OPEN),CLOSE,OPEN,2,0),colorEE00;
STICKLINE(((((CLOSE < REF(CLOSE,1)) AND (CLOSE < REF(CLOSE,1))) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),OPEN,LOW,0.7,0),colorFF0000;
STICKLINE(((((CLOSE < REF(CLOSE,1)) AND (CLOSE < REF(CLOSE,1))) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),CLOSE,HIGH,0.7,0),colorFF0000;
STICKLINE(((((CLOSE < REF(CLOSE,1)) AND (CLOSE < REF(CLOSE,1))) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),CLOSE,OPEN,9,0),colorFF0000;
STICKLINE(((((CLOSE < REF(CLOSE,1)) AND (CLOSE < REF(CLOSE,1))) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),CLOSE,OPEN,6,0),colorFF0000;
STICKLINE(((((CLOSE < REF(CLOSE,1)) AND (CLOSE < REF(CLOSE,1))) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),CLOSE,OPEN,4,0),colorFF0000;
STICKLINE(((((CLOSE < REF(CLOSE,1)) AND (CLOSE < REF(CLOSE,1))) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),CLOSE,OPEN,2,0),colorFF0000;
DRAWICON((((CLOSE < REF(CLOSE,1)) AND (HIGH > 阻挡)) AND (CLOSE < 阻挡)),(HIGH * 1.02),5);
MID:=MA(CLOSE,20);
UPPER:=(MID + (2 * STD(CLOSE,20)));
LOWER:=(MID - (2 * STD(CLOSE,20)));
V1:=(((CLOSE - LOWER) / (UPPER - LOWER)) * 100);
V2:=(V1 - EMA(V1,5));
K1:=(SUM(LLV(V2,4),4) / 4);
V3:=(EMA(V2,64) * 10);
V4:=EMA(((0.4 * V2) * (0 - 1)),3);
V5:=(0 - ((1 * EMA(V2,39)) * 10));
E:=(V3 > 10);
KS:=(V2 > V4);
RKS:=(V5 > 10);
MLS:=(((V3 <= 10) OR (V2 <= V4)) OR (V5 <= 10));
开:=(((CLOSE - SMA(CLOSE,13,1)) / SMA(CLOSE,13,1)) * (0 - 100));
高:=REF(开,1);
低:=((((高 / 开) > 1.23) AND (高 > 13)) AND ((CLOSE / REF(CLOSE,1)) > 1.03));
收:=OPEN;
AAA:=HIGH;
BB:=LOW;
CC1:=CLOSE;
超跌:STICKLINE((开 > 13),AAA,BB,0,1),LINETHICK2,colorFFFFFF;
反弹:STICKLINE((低 = 1),AAA,BB,0,1),LINETHICK2,colorFF00FF;
STICKLINE((开 > 13),收,CC1,8,1),LINETHICK2,colorFFFFFF;
STICKLINE((低 = 1),收,CC1,8,1),LINETHICK2,colorFF00FF;
AA:=(REF(HIGH,3) = HHV(HIGH,((2 * 3) + 1)));
CC:=FILTER(AA,3);
AA2:=BACKSET(CC,(3 + 1));
AAA2:=FILTER(AA2,3);
BB2:=(AAA2 OR ISLASTBAR);
CC22:=(REF(LOW,3) = LLV(LOW,((2 * 3) + 1)));
CC2:=FILTER(CC22,3);
EA:=BACKSET(CC2,(3 + 1));
EB:=FILTER(EA,3);
EE:=(EB AND NOT(AAA2));
FF1:=BACKSET(BB2,(REF(BARSLAST(EE),1) + 1));
EE2:=(FF1 > REF(FF1,1));
FF2:=BACKSET(EE2,2);
EE3:=(FF2 > REF(FF2,1));
FF3:=BACKSET((EE3 AND (COUNT(BB2,(REF(BARSLAST(EE),1) + 2)) = 0)),(REF(BARSLAST(EE),1) + 2));
js:=(FF3 > REF(FF3,1));
G1:=BACKSET((JS AND (COUNT(BB2,(REF(BARSLAST(EE),1) + 2)) = 0)),(REF(BARSLAST(EE),1) + 2));
GA:=(G1 > REF(G1,1));
G2:=IF(BB2,COUNT(EE,(REF(BARSLAST(BB2),1) + 1)),0);
G3:=IF(((G2 = 1) AND BB2),BARSLAST(EE3),0);
GG:=IF((BB2 AND (REF(LOW,BARSLAST(EE3)) >= REF(LOW,BARSLAST(JS)))),BARSLAST(JS),BARSLAST(EE3));
JA:=IF(((G2 = 2) AND BB2),GG,0);
JB:=IF(((G2 >= 3) AND BB2),IF((BB2 AND (REF(LOW,GG) >= REF(LOW,BARSLAST(GA)))),BARSLAST(GA),GG),0);
JJ:=((G3 + JA) + JB);
LD:=BACKSET(BB2,JJ);
LD1:=(LD > REF(LD,1));
HEA:=BACKSET(LD1,2);
HEB:=(HEA > REF(HEA,1));
HEE:=(HEB OR ISLASTBAR);
HFF1:=BACKSET(HEE,(REF(BARSLAST(BB2),1) + 1));
HEE2:=(HFF1 > REF(HFF1,1));
HFF2:=BACKSET(HEE2,2);
HEE3:=(HFF2 > REF(HFF2,1));
HFF3:=BACKSET((HEE3 AND (COUNT(HEE,(REF(BARSLAST(BB2),1) + 2)) = 0)),(REF(BARSLAST(BB2),1) + 2));
Hjs:=(HFF3 > REF(HFF3,1));
HG1:=BACKSET((HJS AND (COUNT(HEE,(REF(BARSLAST(BB2),1) + 2)) = 0)),(REF(BARSLAST(BB2),1) + 2));
HGA:=(HG1 > REF(HG1,1));
HG2:=IF(HEE,COUNT(AAA2,(REF(BARSLAST(HEE),1) + 1)),0);
HG3:=IF(((HG2 = 1) AND HEE),BARSLAST(HEE3),0);
HGG:=IF((HEE AND (REF(HIGH,BARSLAST(HEE3)) <= REF(HIGH,BARSLAST(HJS)))),BARSLAST(HJS),BARSLAST(HEE3));
HJA:=IF(((HG2 = 2) AND HEE),HGG,0);
HJB:=IF(((HG2 >= 3) AND HEE),IF((HEE AND (REF(HIGH,HGG) <= REF(HIGH,BARSLAST(HGA)))),BARSLAST(HGA),HGG),0);
HJJ:=((HG3 + HJA) + HJB);
HD:=BACKSET(HEE,HJJ);
UU:=(HD > REF(HD,1));
VV:=BACKSET(UU,2);
WW:=(VV > REF(VV,1));
XX:=BACKSET(ISLASTBAR,(BARSLAST(HEB) + 1));
UU2:=(XX > REF(XX,1));
VV2:=BACKSET(UU2,(REF(BARSLAST(HEB),1) + 2));
WW2:=(VV2 > REF(VV2,1));
DRAWLINE(WW2,LOW,UU2,LOW,1),POINTDOT,colorFFFF;
XX2:=BACKSET(ISLASTBAR,(BARSLAST(WW) + 1));
前一低:=(XX2 > REF(XX2,1));
上:=BACKSET(前一低,(REF(BARSLAST(WW),1) + 2));
中1:=(上 > REF(上,1));
DRAWLINE(中1,HIGH,前一低,HIGH,1),POINTDOT,colorFFFF;
中2:=REF(LOW,BARSLAST(UU2));
前二低:REF(LOW,BARSLAST(WW2)),POINTDOT,LINETHICK2,colorFF66FF;
前一高:REF(HIGH,BARSLAST(前一低)),POINTDOT,LINETHICK3,color99FF66;
前二高:REF(HIGH,BARSLAST(中1)),POINTDOT,LINETHICK2,colorFF66FF;
下:=(MA(HIGH,30) * 1.15);
上通道:=(MA(HIGH,3) * 1.03);
短期乖离率:=(MA(LOW,3) * 0.97);
趋势:=(MA(LOW,30) * 0.85);
趋势1:=(EMA(EMA(EMA(HIGH,5),5),5) * 1.05);
DRAWTEXT(FILTER(((HIGH > 趋势1) AND (CLOSE < 趋势1)),3),(HIGH * 1.04),''),colorEE00FF;
平衡线:=(((CLOSE - MA(CLOSE,13)) / MA(CLOSE,13)) * 100);
回挡线:=(((5 * SMA((((CLOSE - LLV(LOW,9)) / (HHV(HIGH,9) - LLV(LOW,9))) * 80),5,1)) - (3 * SMA(SMA((((CLOSE - LLV(LOW,7)) / (HHV(HIGH,7) - LLV(LOW,7))) * 80),5,1),3,1))) - SMA(SMA(SMA((((CLOSE - LLV(LOW,20)) / (HHV(HIGH,20) - LLV(LOW,20))) * 80),5,1),3,1),2,1));
中期大底:=MA(MA(回挡线,5),3);
了结线:=EMA(EMA(EMA(HIGH,3),3),1);
WX:=(了结线 * 0.92);
DRAWICON(((CROSS(回挡线,0) AND (平衡线 > 3)) AND ((WX - REF(WX,1)) > 0)),LOW,0);
M1:=(LLV(LOW,30) * 1.01);
DRAWTEXT((((LOW <= M1) AND ((WX - REF(WX,1)) >= (0 - 0.99999))) AND ((CLOSE / OPEN) > 1.025)),LOW,''),colorFFFF;
VAR2:=(了结线 * 0.84);
M2:=(了结线 * 1.06);
主线:=WMA(CLOSE,8);
VAR1:=POW((CLOSE - 主线),1);
VAR2:=MA(VAR1,3);
VAR3:=SQRT(VAR2);
MA10:=MA(CLOSE,0);
平均值:=(MA(CLOSE,15) * IF((20 < 5),MA10,1));
MX:=(MA(CLOSE,20) * IF((20 < 7),MA10,1));
DRAWTEXT((((((((REF(CLOSE,1) < MX) AND ((主线 - REF(主线,1)) > 0)) AND ((M2 - REF(M2,1)) > 0.01)) AND (LOW < MX)) AND (CLOSE > MX)) AND ((平均值 - REF(平均值,1)) > 0)) AND ((CLOSE / OPEN) > 1.052)),(LOW - 0.08),'★黄金'),colorFFFF;
MA13:=MA(CLOSE,10);
MA34:=((MA13 / -10) + MA13);
VAR190:=((MA34 * 2) * 0.54);
VAR191:=MA(CLOSE,13);
VAR192:=MA(CLOSE,25);
DRAWTEXT(FILTER((((((((下 - REF(下,1)) > 0) AND (平衡线 < (0 - 4))) AND (CLOSE < OPEN)) AND (LOW <= VAR192)) AND (CLOSE < VAR191)) AND ((VAR190 - REF(VAR190,1)) > 0)),1),LOW,'★破多买入'),colorFFFFFF;

202108211125.jpg

202108211125.jpg

 

回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则