米老鼠和蓝精鼠v 发表于 2023-9-9 10:55:05

画线指标缠中说禅之缠高点主图指标

<p><br></p><section></section><section></section><section></section><p>公式源码:</p><p>K:=1;</p><p>局部低点预选A:=BACKSET(LLV(L,5)&lt;REF(LLV(L,4),1),4);</p><p>局部低点预选B:=BACKSET(局部低点预选A=0 AND REF(局部低点预选A,1)=1,2);</p><p>局部低点预选C:=IF(局部低点预选B=1 AND REF(局部低点预选B,1)=0,-1,0);</p><p>局部高点预选A:=BACKSET(HHV(H,5)&gt;REF(HHV(H,4),1),4);</p><p>局部高点预选B:=BACKSET(局部高点预选A=0 AND REF(局部高点预选A,1)=1,2);</p><p>局部高点预选C:=IF(局部高点预选B=1 AND REF(局部高点预选B,1)=0,1,0);</p><p>缺口判断:=IF(L&gt;REF(H,1),1,IF(H&lt;REF(L,1),-1,0));</p><p>距前高天:=BARSLAST(局部高点预选C=1);</p><p>距前低天:=BARSLAST(局部低点预选C=-1);</p><p>小值周期:=LOWRANGE(L);</p><p>大值周期:=TOPRANGE(H);</p><p>低保留AA:=IF(局部低点预选C=-1 AND REF(距前高天,1)&gt;REF(距前低天,1) AND LLV(L,距前高天+1)&lt;REF(LLV(L,距前高天+1),1),-1,0);</p><p>低保留AB:=IF(局部低点预选C=-1 AND REF(距前高天,1)&lt;=REF(距前低天,1) AND (距前高天&gt;=4 OR LLV(缺口判断,距前高天)=-1 OR LLV(L,距前低天+2)&lt;REF(LLV(L,距前低天+1),1)),-1,0);</p><p>低保留S:=IF((低保留AA=-1 OR 低保留AB=-1) AND L&lt;REF(H,距前高天+1),-1,0);</p><p>预判:=IF((距前低天&lt;4 AND HHV(缺口判断,距前低天)!=1) OR REF(低保留S,距前低天)=0,1,0);</p><p>判断:=IF(局部高点预选C=1 AND REF(距前低天,1)&lt;=REF(距前高天,1) AND 预判=1 AND 大值周期&gt;REF(小值周期,距前低天+1) AND 大值周期&gt;REF(小值周期,距前低天) AND 大值周期&gt;REF(大值周期,距前高天),1,0);</p><p>高保留A:=IF(局部高点预选C=1 AND REF(距前低天,1)&gt;REF(距前高天,1) AND HHV(H,距前低天+1)&gt;REF(HHV(H,距前低天+1),1),1,0);</p><p>高保留B:=IF(局部高点预选C=1 AND REF(距前低天,1)&lt;=REF(距前高天,1) AND REF(低保留S,距前低天)=-1 AND (距前低天&gt;=4 OR HHV(缺口判断,距前低天)=1),1,0);</p><p>高保留:=IF((高保留A=1 OR 高保留B=1 OR 判断=1) AND H&gt;REF(L,距前低天+1),1,0);</p><p>预判A:=IF((距前高天&lt;4 AND HHV(缺口判断,距前高天)!=1) OR REF(高保留,距前高天)=0,1,0);</p><p>判断A:=IF(局部低点预选C=-1 AND REF(距前高天,1)&lt;=REF(距前低天,1) AND 预判A=1 AND 小值周期&gt;REF(大值周期,距前高天+1) AND 小值周期&gt;REF(大值周期,距前高天) AND 小值周期&gt;REF(小值周期,距前低天),-1,0);</p><p>低保留A:=IF(局部低点预选C=-1 AND REF(距前高天,1)&gt;REF(距前低天,1) AND LLV(L,距前高天+1)&lt;REF(LLV(L,距前高天+1),1),-1,0);</p><p>低保留B:=IF(局部低点预选C=-1 AND REF(距前高天,1)&lt;=REF(距前低天,1) AND (距前高天&gt;=4 OR LLV(缺口判断,距前高天)=-1 OR 判断A=-1),-1,0);</p><p>低保留:=IF((低保留A=-1 OR 低保留B=-1) AND L&lt;REF(H,距前高天+1),-1,0);</p><p>距前高天A:=BARSLAST(高保留=1);</p><p>距前低天A:=BARSLAST(低保留=-1);</p><p>预判X:=IF((距前低天A&lt;4 AND HHV(缺口判断,距前低天A)!=1) OR REF(低保留,距前低天A)=0,1,0);</p><p>判断X:=IF(局部高点预选C=1 AND REF(距前低天A,1)&lt;=REF(距前高天A,1) AND 预判X=1 AND 大值周期&gt;REF(小值周期,距前低天A+1) AND 大值周期&gt;REF(小值周期,距前低天A) AND 大值周期&gt;REF(大值周期,距前高天A),1,0);</p><p>高保留XA:=IF(局部高点预选C=1 AND REF(距前低天A,1)&gt;REF(距前高天A,1) AND HHV(H,距前低天A+1)&gt;REF(HHV(H,距前低天A+1),1),1,0);</p><p>高保留XB:=IF(局部高点预选C=1 AND REF(距前低天A,1)&lt;=REF(距前高天A,1) AND REF(低保留,距前低天A)=-1 AND (距前低天A&gt;=4 OR HHV(缺口判断,距前低天A)=1),1,0);</p><p>高保留X:=IF((高保留XA=1 OR 高保留XB=1 OR 判断X=1) AND H&gt;REF(L,距前低天A+1),1,0);</p><p>预判XA:=IF((距前高天A&lt;4 AND HHV(缺口判断,距前高天A)!=1) OR REF(高保留XA,距前高天A)=0,1,0);</p><p>判断XA:=IF(局部低点预选C=-1 AND REF(距前高天A,1)&lt;=REF(距前低天A,1) AND 预判XA=1 AND 小值周期&gt;REF(大值周期,距前高天A+1) AND 小值周期&gt;REF(大值周期,距前高天A) AND 小值周期&gt;REF(小值周期,距前低天A),-1,0);</p><p>低保留XA:=IF(局部低点预选C=-1 AND REF(距前高天A,1)&gt;REF(距前低天A,1) AND LLV(L,距前高天A+1)&lt;REF(LLV(L,距前高天A+1),1),-1,0);</p><p>低保留XB:=IF(局部低点预选C=-1 AND REF(距前高天A,1)&lt;=REF(距前低天A,1) AND (距前高天A&gt;=4 OR LLV(缺口判断,距前高天A)=-1 OR 判断XA=-1),-1,0);</p><p>低保留X:=IF((低保留XA=-1 OR 低保留XB=-1) AND L&lt;REF(H,距前高天A+1),-1,0);</p><p>距前高天YA:=BARSLAST(高保留X=1);</p><p>距前低天YA:=BARSLAST(低保留X=-1);</p><p>预判YX:=IF((距前低天YA&lt;4 AND HHV(缺口判断,距前低天YA)!=1) OR REF(低保留X,距前低天YA)=0,1,0);</p><p>判断YX:=IF(局部高点预选C=1 AND REF(距前低天YA,1)&lt;=REF(距前高天YA,1) AND 预判YX=1 AND 大值周期&gt;REF(小值周期,距前低天YA+1) AND 大值周期&gt;REF(小值周期,距前低天YA) AND 大值周期&gt;REF(大值周期,距前高天YA),1,0);</p><p>高保留YXA:=IF(局部高点预选C=1 AND REF(距前低天YA,1)&gt;REF(距前高天YA,1) AND HHV(H,距前低天YA+1)&gt;REF(HHV(H,距前低天YA+1),1),1,0);</p><p>高保留YXB:=IF(局部高点预选C=1 AND REF(距前低天YA,1)&lt;=REF(距前高天YA,1) AND REF(低保留X,距前低天YA)=-1 AND (距前低天YA&gt;=4 OR HHV(缺口判断,距前低天YA)=1),1,0);</p><p>高保留YX:=IF((高保留YXA=1 OR 高保留YXB=1 OR 判断YX=1) AND H&gt;REF(L,距前低天YA+1),1,0);</p><p>预判YXA:=IF((距前高天YA&lt;4 AND HHV(缺口判断,距前高天YA)!=1) OR REF(高保留YXA,距前高天YA)=0,1,0);</p><p>判断YXA:=IF(局部低点预选C=-1 AND REF(距前高天YA,1)&lt;=REF(距前低天YA,1) AND 预判YXA=1 AND 小值周期&gt;REF(大值周期,距前高天YA+1) AND 小值周期&gt;REF(大值周期,距前高天YA) AND 小值周期&gt;REF(小值周期,距前低天YA),-1,0);</p><p>低保留YXA:=IF(局部低点预选C=-1 AND REF(距前高天YA,1)&gt;REF(距前低天YA,1) AND LLV(L,距前高天YA+1)&lt;REF(LLV(L,距前高天YA+1),1),-1,0);</p><p>低保留YXB:=IF(局部低点预选C=-1 AND REF(距前高天YA,1)&lt;=REF(距前低天YA,1) AND (距前高天YA&gt;=4 OR LLV(缺口判断,距前高天YA)=-1 OR 判断YXA=-1),-1,0);</p><p>低保留YX:=IF((低保留YXA=-1 OR 低保留YXB=-1) AND L&lt;REF(H,距前高天YA+1),-1,0);</p><p>AAAD:=IF(高保留YX=1 AND 低保留YX=-1 AND H&gt;REF(H,REF(距前高天YA,1)+2),1,IF(高保留YX=1 AND 低保留YX=-1 AND L&lt;REF(L,REF(距前低天YA,1)+2),-1,0));</p><p>极点保留:=IF(AAAD=0,高保留YX+低保留YX,AAAD);</p><p>局部极点:IF(极点保留=-1,L,IF(极点保留=1,H,DRAWNULL)),CIRCLEDOT,COLORYELLOW;</p><p>局部天数:BARSLAST(ABS(极点保留)),NODRAW;</p><p>局部换手:IF(极点保留=0,SUM(&#34;HSL.HSL&#34;,局部天数),0),NODRAW;</p><p>局部涨跌:C/REF(C,局部天数)*100-100,NODRAW,COLORWHITE;</p><p>换手G:=VARCAT(VAR2STR(SUM(&#34;HSL.HSL&#34;,BARSLAST(高保留X)),2),&#39;%H &#39;);</p><p>高点换手:=VARCAT(VARCAT(VARCAT(换手G,&#39;(&#39;),VAR2STR(BARSLAST(高保留X),0)),&#39;T)&#39;);</p><p>换手D:=VARCAT(VAR2STR(SUM(&#34;HSL.HSL&#34;,BARSLAST(低保留X)),2),&#39;%H &#39;);</p><p>低点换手:=VARCAT(VARCAT(&#39;(&#39;,VAR2STR(BARSLAST(低保留X),0)),&#39;天)&#39;);</p><p>高跌幅:=IF(K=1,L/REF(H,BARSLAST(高保留X))*100-100,C/REF(C,BARSLAST(高保留X))*100-100);</p><p>低涨幅:=IF(K=1,H/REF(L,BARSLAST(低保留X))*100-100,C/REF(C,BARSLAST(低保留X))*100-100);</p><p>高跌幅A:=VARCAT(VAR2STR(高跌幅,2),&#39;%幅&#39;);</p><p>低涨幅A:=VARCAT(VAR2STR(低涨幅,2),&#39;%幅&#39;);</p><p>高点显示:=VARCAT(低点换手,低涨幅A);</p><p>低点显示:=VARCAT(高点换手,高跌幅A);</p><p>DRAWLINE(极点保留=-1,局部极点,极点保留=1,局部极点,0),COLORLIRED;</p><p>DRAWLINE(极点保留=1,局部极点,极点保留=-1,局部极点,0),COLORYELLOW;</p><p>DRAWTEXT(极点保留=-1,L*0.99,局部换手),COLORGREEN;</p><p>DRAWTEXT(极点保留=1,H*1.01,高点显示),COLORYELLOW;</p><p>{DRAWNUMBER(极点保留=1,H,局部极点);}</p><p>DRAWNUMBER(极点保留=-1,L,局部极点),DRAWABOVE;</p>

123459628 发表于 2023-11-9 18:41:45

功德无量!

卫蒙更夜沙 发表于 2023-12-19 07:34:40

非常好,赞一个!

雨玲612 发表于 2023-12-23 08:34:46

找了很久了,多谢!

对水阳北命 发表于 2024-3-12 15:30:21

已收藏!
页: [1]
查看完整版本: 画线指标缠中说禅之缠高点主图指标