支撑压力通达信公式 主图 贴图和谐源码分享

VAR1:=BACKSET(LLV(LOW,5)<REF(LLV(LOW,4),1),4);
VAR2:=BACKSET(VAR1=0 AND REF(VAR1,1)=1,2);
VAR3:=IF(VAR2=1 AND REF(VAR2,1)=0,(-1),0);
VAR4:=BACKSET(HHV(HIGH,5)>REF(HHV(HIGH,4),1),4);
VAR5:=BACKSET(VAR4=0 AND REF(VAR4,1)=1,2);
VAR6:=IF(VAR5=1 AND REF(VAR5,1)=0,1,0);
VAR7:=IF(LOW>REF(HIGH,1),1,IF(HIGH<REF(LOW,1),(-1),0));
VAR8:=BARSLAST(VAR6=1);
VAR9:=BARSLAST(VAR3=(-1));
VAR10:=LOWRANGE(LOW);
VAR11:=TOPRANGE(HIGH);
{}
VAR12:=IF(VAR3=(-1) AND REF(VAR8,1)>REF(VAR9,1) AND LLV(LOW,VAR8+1)<REF(LLV(LOW,VAR8+1),1),(-1),0);
VAR13:=IF(VAR3=(-1) AND REF(VAR8,1)<=REF(VAR9,1) AND (VAR8>=4 OR LLV(VAR7,VAR8)=(-1) OR LLV(LOW,VAR9+2)<REF(LLV(LOW,VAR9+1),1)),(-1),0);
VAR14:=IF(VAR12=(-1) OR VAR13=(-1) AND LOW<REF(HIGH,VAR8+1),(-1),0);
VAR15:=IF(VAR9<4 AND HHV(VAR7,VAR9)!=1 OR REF(VAR14,VAR9)=0,1,0);
VAR16:=IF(VAR6=1 AND REF(VAR9,1)<=REF(VAR8,1) AND VAR15=1 AND VAR11>REF(VAR10,VAR9+1) AND VAR11>REF(VAR10,VAR9) AND VAR11>REF(VAR11,VAR8),1,0);
VAR17:=IF(VAR6=1 AND REF(VAR9,1)>REF(VAR8,1) AND HHV(HIGH,VAR9+1)>REF(HHV(HIGH,VAR9+1),1),1,0);
VAR18:=IF(VAR6=1 AND REF(VAR9,1)<=REF(VAR8,1) AND REF(VAR14,VAR9)=(-1) AND (VAR9>=4 OR HHV(VAR7,VAR9)=1),1,0);
VAR19:=IF(VAR17=1 OR VAR18=1 OR VAR16=1 AND HIGH>REF(LOW,VAR9+1),1,0);
VAR20:=IF(VAR8<4 AND HHV(VAR7,VAR8)!=1 OR REF(VAR19,VAR8)=0,1,0);
VAR21:=IF(VAR3=(-1) AND REF(VAR8,1)<=REF(VAR9,1) AND VAR20=1 AND VAR10>REF(VAR11,VAR8+1) AND VAR10>REF(VAR11,VAR8) AND VAR10>REF(VAR10,VAR9),(-1),0);
VAR22:=IF(VAR3=(-1) AND REF(VAR8,1)>REF(VAR9,1) AND LLV(LOW,VAR8+1)<REF(LLV(LOW,VAR8+1),1),(-1),0);
VAR23:=IF(VAR3=(-1) AND REF(VAR8,1)<=REF(VAR9,1) AND (VAR8>=4 OR LLV(VAR7,VAR8)=(-1) OR VAR21=(-1)),(-1),0);
VAR24:=IF(VAR22=(-1) OR VAR23=(-1) AND LOW<REF(HIGH,VAR8+1),(-1),0);
VAR25:=BARSLAST(VAR19=1);
VAR26:=BARSLAST(VAR24=(-1));
VAR27:=IF(VAR26<4 AND HHV(VAR7,VAR26)!=1 OR REF(VAR24,VAR26)=0,1,0);
VAR28:=IF(VAR6=1 AND REF(VAR26,1)<=REF(VAR25,1) AND VAR27=1 AND VAR11>REF(VAR10,VAR26+1) AND VAR11>REF(VAR10,VAR26) AND VAR11>REF(VAR11,VAR25),1,0);
VAR29:=IF(VAR6=1 AND REF(VAR26,1)>REF(VAR25,1) AND HHV(HIGH,VAR26+1)>REF(HHV(HIGH,VAR26+1),1),1,0);
VAR30:=IF(VAR6=1 AND REF(VAR26,1)<=REF(VAR25,1) AND REF(VAR24,VAR26)=(-1) AND (VAR26>=4 OR HHV(VAR7,VAR26)=1),1,0);
VAR31:=IF(VAR29=1 OR VAR30=1 OR VAR28=1 AND HIGH>REF(LOW,VAR26+1),1,0);
VAR32:=IF(VAR25<4 AND HHV(VAR7,VAR25)!=1 OR REF(VAR29,VAR25)=0,1,0);
VAR33:=IF(VAR3=(-1) AND REF(VAR25,1)<=REF(VAR26,1) AND VAR32=1 AND VAR10>REF(VAR11,VAR25+1) AND VAR10>REF(VAR11,VAR25) AND VAR10>REF(VAR10,VAR26),(-1),0);
VAR34:=IF(VAR3=(-1) AND REF(VAR25,1)>REF(VAR26,1) AND LLV(LOW,VAR25+1)<REF(LLV(LOW,VAR25+1),1),(-1),0);
VAR35:=IF(VAR3=(-1) AND REF(VAR25,1)<=REF(VAR26,1) AND (VAR25>=4 OR LLV(VAR7,VAR25)=(-1) OR VAR33=(-1)),(-1),0);
VAR36:=IF(VAR34=(-1) OR VAR35=(-1) AND LOW<REF(HIGH,VAR25+1),(-1),0);
VAR37:=BARSLAST(VAR31=1);
VAR38:=BARSLAST(VAR36=(-1));
VAR39:=IF(VAR38<4 AND HHV(VAR7,VAR38)!=1 OR REF(VAR36,VAR38)=0,1,0);
VAR40:=IF(VAR6=1 AND REF(VAR38,1)<=REF(VAR37,1) AND VAR39=1 AND VAR11>REF(VAR10,VAR38+1) AND VAR11>REF(VAR10,VAR38) AND VAR11>REF(VAR11,VAR37),1,0);
VAR41:=IF(VAR6=1 AND REF(VAR38,1)>REF(VAR37,1) AND HHV(HIGH,VAR38+1)>REF(HHV(HIGH,VAR38+1),1),1,0);
VAR42:=IF(VAR6=1 AND REF(VAR38,1)<=REF(VAR37,1) AND REF(VAR36,VAR38)=(-1) AND (VAR38>=4 OR HHV(VAR7,VAR38)=1),1,0);
VAR43:=IF(VAR41=1 OR VAR42=1 OR VAR40=1 AND HIGH>REF(LOW,VAR38+1),1,0);
VAR44:=IF(VAR37<4 AND HHV(VAR7,VAR37)!=1 OR REF(VAR41,VAR37)=0,1,0);
VAR45:=IF(VAR3=(-1) AND REF(VAR37,1)<=REF(VAR38,1) AND VAR44=1 AND VAR10>REF(VAR11,VAR37+1) AND VAR10>REF(VAR11,VAR37) AND VAR10>REF(VAR10,VAR38),(-1),0);
VAR46:=IF(VAR3=(-1) AND REF(VAR37,1)>REF(VAR38,1) AND LLV(LOW,VAR37+1)<REF(LLV(LOW,VAR37+1),1),(-1),0);
VAR47:=IF(VAR3=(-1) AND REF(VAR37,1)<=REF(VAR38,1) AND (VAR37>=4 OR LLV(VAR7,VAR37)=(-1) OR VAR45=(-1)),(-1),0);
VAR48:=IF(VAR46=(-1) OR VAR47=(-1) AND LOW<REF(HIGH,VAR37+1),(-1),0);
VAR49:=IF(VAR43=1 AND VAR48=(-1) AND HIGH>REF(HIGH,REF(VAR37,1)+2),1,IF(VAR43=1 AND VAR48=(-1) AND LOW<REF(LOW,REF(VAR38,1)+2),(-1),0));
VAR50:=IF(VAR49=0,VAR43+VAR48,VAR49);
VAR51:=DRAWLINE(VAR50=(-1),LOW,REF(VAR50,1)=(-1),REF(LOW,1),1);
VAR52:=DRAWLINE(VAR50=1,HIGH,REF(VAR50,1)=1,REF(HIGH,1),1);
VAR53:=DRAWLINE(VAR50=(-1),VAR52,REF(VAR50,1)=(-1),REF(VAR52,1),1);
VAR54:=DRAWLINE(VAR50=1,VAR51,REF(VAR50,1)=1,REF(VAR51,1),1);
VAR55:=(VAR51+VAR53)/2;
VAR56:=(VAR52+VAR54)/2;
VAR57:=(VAR53-VAR51)*3/4+VAR51;
VAR58:=VAR52-(VAR52-VAR54)*3/4;
DRAWBAND(VAR55,RGB(0,150,100),VAR57,RGB(0,150,100));
DRAWBAND(VAR56,RGB(185,96,9),VAR58,RGB(185,96,9));
局部极点:IF(VAR50=(-1),LOW,IF(VAR50=1,HIGH,DRAWNULL)),CIRCLEDOT,COLORYELLOW,LINETHICK5;
压1:IF(BETWEEN(VAR55,VAR56,VAR58),VAR55,DRAWNULL),COLOR008800;
压2:IF(BETWEEN(VAR57,VAR56,VAR58),VAR57,DRAWNULL),COLOR008800;
过压底:REF(CLOSE,1)<VAR55 AND CLOSE>VAR55 AND CLOSE<35 AND CAPITAL<6000000,NODRAW,COLORYELLOW;
过压顶:REF(CLOSE,1)<VAR57 AND CLOSE>VAR57 AND CLOSE<35 AND CAPITAL<6000000,NODRAW;
支撑底:REF(CLOSE,1)<VAR58 AND CLOSE>VAR58 AND CLOSE<35 AND CAPITAL<6000000,NODRAW;
支撑顶:REF(CLOSE,1)<VAR56 AND CLOSE>VAR56 AND CLOSE<35 AND CAPITAL<6000000,NODRAW;
DRAWKLINE(HIGH,OPEN,LOW,CLOSE);
VAR59:=EMA(EMA(VOL,5),5);
VAR60:=EMA(EMA(VOL,35),35);
VAR61:=VOL/((HIGH-LOW)*2-ABS(CLOSE-OPEN));
VAR62:=VOL;
VAR63:=IF(CLOSE>OPEN,VAR61*(HIGH-LOW),IF(CLOSE<OPEN,VAR61*(HIGH-OPEN+(CLOSE-LOW)),VOL/2));
VAR64:=IF(CLOSE>OPEN,VAR61*(HIGH-CLOSE+(OPEN-LOW)),IF(CLOSE<OPEN,VAR61*(HIGH-LOW),VOL/2));
VAR65:=VOL/(VAR63-VAR64);
VAR66:=VAR63/VAR64;
VAR67:=VAR66/REF(VAR66,1);
净买:(VAR63-VAR64)/100,NODRAW;
VAR68:=VAR66>4;
VAR69:=净买<0;
净买天数:BARSLAST(VAR69),NODRAW,COLORMAGENTA;
STICKLINE(净买>0,CLOSE,OPEN,3,0),COLORRED;
STICKLINE(净买<0,CLOSE,OPEN,1.8,0),COLORGREEN;
STICKLINE(VAR68,CLOSE,OPEN,2,0),COLORYELLOW;
STICKLINE(VAR65>9,HIGH,OPEN,3,0),COLORWHITE;
 


未来函数检测结果如下:
该公式包含未来函数:BACKSET
该公式包含未来函数:CAPITAL
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式

联系我们  |  股票指标网  |  指标网   |  指标公式  |   加入收藏   |  设为主页

@2005-2023 粤ICP备2023063687号-2 股票指标网别名指标网仅为互联网文章,所有股票指标公式及文章仅供学习研究,并不构成投资建议,请勿以此为依据进行股票交易,由此引起的投资亏损与本站无关。股票指标网均来源互联网收集整理,如不慎侵犯了你的权益,请联系我们告知,我们将做删除处理
QQ:88652583 微信 88652583
sitemap站点地图