通达信【发现嘿马】副图买入逃顶 源码分享
趋势:EMA((C-MA((2*C+HIGH+LOW)/4,30))/MA((2*C+HIGH+LOW)/4,30)*100,3),COLORMAGENTA,LINETHICK1;界线:0,COLORRED;STICKLINE(趋势< -10,0,趋势,0.8,0),COLORRED;STICKLINE(趋势>10,0,趋势,0.8,0),COLORLICYAN;RSV:=(((C - LLV(LOW,9)) / (HHV(HIGH,9) - LLV(LOW,9))) * 100);K:=SMA(RSV,3,1);D:=SMA(K,3,1);J:=((3 * K) - (2 * D));ZBVARA1:=(((C - MA(C,6)) / MA(C,6)) * 100);ZBVARA2:=(((C - MA(C,12)) / MA(C,12)) * 100);ZBVARA3:=(((C - MA(C,24)) / MA(C,24)) * 100);ZBVARA4:=(((ZBVARA1 + (2 * ZBVARA2)) + (3 * ZBVARA3)) / 6);ZBVARA5:=MA(ZBVARA4,3);STICKLINE((CROSS(J,0) AND (ZBVARA5 <= (0 - 7))),0,35,3,0),COLORMAGENTA;DRAWTEXT((CROSS(J,0) AND (ZBVARA5 <= (0 - 7))),33.5,'发'),COLOR4080FF;DRAWTEXT((CROSS(J,0) AND (ZBVARA5 <= (0 - 7))),25.5,'现'),COLOR4080FF;DRAWTEXT((CROSS(J,0) AND (ZBVARA5 <= (0 - 7))),17.5,'黑'),COLOR4080FF;DRAWTEXT((CROSS(J,0) AND (ZBVARA5 <= (0 - 7))),9.5,'马'),COLOR4080FF;发现黑马:CROSS(J,0) AND (ZBVARA5 <= (0 - 7)),COLORMAGENTA,NODRAW;LC:=REF(C,1);WWW70822COM:DRAWNULL,COLORRED;RSI:=SMA(MAX(C-LC,0),6,1)/SMA(ABS(C-LC),6,1)*100;顶部:=CROSS(80,RSI)*1,LINETHICK2 ,COLORGREEN;DRAWTEXT(CROSS(80,RSI),-1,'顶 '),COLOR408000;STICKLINE(CROSS(80,RSI),0,趋势,0.8,0),COLOR408000;顶:顶部,COLOR408000,NODRAW;
来函数检测结果如下:
该公式没有未来函数
解密、编写股票、期货策略请联系QQ或微信同号:88652583
相关股票指标公式
原理解析:
输出趋势:EMA((C-MA((2*C+最高价+最低价)/4,30))/MA((2*C+最高价+最低价)/4,30)*100,3),画洋红色,LINETHICK1
输出界线:0,COLORRED
当满足条件趋势< -10时,在0和趋势之间画柱状线
当满足条件趋势>10时,在0和趋势之间画柱状线
RSV赋值:(((C - 9日内最低价最低值) / (9日内最高价最高值 - 9日内最低价最低值)) * 100)
RSV的3日[1日权重]移动平均
K的3日[1日权重]移动平均
J赋值:((3 * K) - (2 * D))
ZBVARA1赋值:(((C - C的6日简单移动平均) / C的6日简单移动平均) * 100)
ZBVARA2赋值:(((C - C的12日简单移动平均) / C的12日简单移动平均) * 100)
ZBVARA3赋值:(((C - C的24日简单移动平均) / C的24日简单移动平均) * 100)
ZBVARA4赋值:(((ZBVARA1 + (2 * ZBVARA2)) + (3 * ZBVARA3)) / 6)
ZBVARA5赋值:ZBVARA4的3日简单移动平均
STICKLINE((J上穿0 AND (ZBVARA5 <= (0 - 7))),0,35,3,0),画洋红色
DRAWTEXT((J上穿0 AND (ZBVARA5 <= (0 - 7))),33.5,'发'),COLOR4080FF
DRAWTEXT((J上穿0 AND (ZBVARA5 <= (0 - 7))),25.5,'现'),COLOR4080FF
DRAWTEXT((J上穿0 AND (ZBVARA5 <= (0 - 7))),17.5,'黑'),COLOR4080FF
DRAWTEXT((J上穿0 AND (ZBVARA5 <= (0 - 7))),9.5,'马'),COLOR4080FF
输出发现黑马:J上穿0 AND (ZBVARA5 <= (0 - 7)),画洋红色,NODRAW
LC赋值:1日前的C
输出WWW70822COM:DRAWNULL,COLORRED
RSI赋值:SMA(C-LC和0较大值,6,1)/SMA(C-LC的绝对值,6,1)*100
顶部赋值:80上穿RSI*1,LINETHICK2 ,画绿色
DRAWTEXT(80上穿RSI,-1,'顶 '),COLOR408000
STICKLINE(80上穿RSI,0,趋势,0.8,0),COLOR408000
输出顶:顶部,COLOR408000,NODRAW