九毛八公式指标
请老师帮忙编写个公式: 条件: 1、MACD 在0轴上 2、MACD在死叉后出现金叉 麻烦老师给予解决。谢谢选!!!
公式模块:
SS:=BArslAST(DISPSTATUS=1)+1;
HH:=HHVALL(HHV(H,SS)); LL:=LLVALL(LLV(L,SS)); ZZ:=(HH-LL)/10; SZ:=HHVALL(SS)-SS+1; HL1:=HHVALL(SUM((C>=HH-ZZ*1)*V,SS)); HL2:=HHVALL(SUM((C<HH-ZZ*1 AND C>=HH-ZZ*2)*V,SS)); HL3:=HHVALL(SUM((C<HH-ZZ*2 AND C>=HH-ZZ*3)*V,SS)); HL4:=HHVALL(SUM((C<HH-ZZ*3 AND C>=HH-ZZ*4)*V,SS)); HL5:=HHVALL(SUM((C<HH-ZZ*4 AND C>=HH-ZZ*5)*V,SS)); HL6:=HHVALL(SUM((C<HH-ZZ*5 AND C>=HH-ZZ*6)*V,SS)); HL7:=HHVALL(SUM((C<HH-ZZ*6 AND C>=HH-ZZ*7)*V,SS)); HL8:=HHVALL(SUM((C<HH-ZZ*7 AND C>=HH-ZZ*8)*V,SS)); HL9:=HHVALL(SUM((C<HH-ZZ*8 AND C>=HH-ZZ*9)*V,SS)); HL10:=HHVALL(SUM((C<HH-ZZ*9)*V,SS)); ZV:=HL1+HL2+HL3+HL4+HL5+HL6+HL7+HL8+HL9+HL10; STICKLINE(HL1/ZV*HHVALL(SS)*3>=SZ,HH,(HH-ZZ)*1.01,20,0),COLOR3C3C3A; STICKLINE(HL2/ZV*HHVALL(SS)*3>=SZ,(HH-ZZ),(HH-ZZ*2)*1.01,20,0),COLOR3C3C3A; STICKLINE(HL3/ZV*HHVALL(SS)*3>=SZ,(HH-ZZ*2),(HH-ZZ*3)*1.01,20,0),COLOR3C3C3A; STICKLINE(HL4/ZV*HHVALL(SS)*3>=SZ,(HH-ZZ*3),(HH-ZZ*4)*1.01,20,0),COLOR3C3C3A; STICKLINE(HL5/ZV*HHVALL(SS)*3>=SZ,(HH-ZZ*4),(HH-ZZ*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