老师帮忙改个公式 [文华财经]
- 咨询内容:
老师帮忙改个公式,这个指标会连续出信号,想改成在出第一个信号后开仓,平仓后再出下一个信号,在持仓过程中没有信号出现
A:MA(C,20);DIFF : =EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);DEA := EMA(DIFF,M);MACD:=2*(DIFF-DEA),COLORSTICK;MID:MA(CLOSE,N),COLORMAGENTA;TMP2:=STD(CLOSE,W);TOP:MID+P*TMP2,COLORMAGENTA;BOTTOM:MID-P*TMP2,COLORMAGENTA;DRAWICON(MA(C,60)>REF(MA(C,60),1)&&DIFF>0&&DEA>0&&2*(DIFF-DEA)>0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1),C,'ICO1'),BK;DRAWICON(MA(C,60)<REF(MA(C,60),1)&&DIFF<0&&DEA<0&&2*(DIFF-DEA)<0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1),C,'ICO2'),SK;C<A,SP;C>A,BP;AUTOFILTER;CHECKSIG(SP,'A',0,'C',0,0);CHECKSIG(BP,'A',0,'C',0,0); - 文华技术人员:
请参考:
A:MA(C,20);
DIFF:=EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);
DEA:= EMA(DIFF,M);
MACD:=2*(DIFF-DEA),COLORSTICK;
MID:MA(CLOSE,N),COLORMAGENTA;
TMP2:=STD(CLOSE,W);
TOP:MID+P*TMP2,COLORMAGENTA;
BOTTOM:MID-P*TMP2,COLORMAGENTA;
DRAWICON(MA(C,60)>REF(MA(C,60),1)&&DIFF>0&&DEA>0&&2*(DIFF-DEA)>0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1),C,'ICO1');
DRAWICON(MA(C,60)<REF(MA(C,60),1)&&DIFF<0&&DEA<0&&2*(DIFF-DEA)<0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1),C,'ICO2');
MA(C,60)>REF(MA(C,60),1)&&DIFF>0&&DEA>0&&2*(DIFF-DEA)>0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1),BK;
MA(C,60)<REF(MA(C,60),1)&&DIFF<0&&DEA<0&&2*(DIFF-DEA)<0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1),SK;
C<A,SP;
C>A,BP;
AUTOFILTER;
CHECKSIG(SP,'A',0,'C',0,0);
CHECKSIG(BP,'A',0,'C',0,0); - 文华客服:
还是有连续图标,附件有图,这个图标怎么让其不连续出?
文件名:qq图片20170316132032.png
- 网友回复:
请参考:
A:MA(C,20);
DIFF:=EMA(CLOSE,SHORT) - EMA(CLOSE,LONG);
DEA:= EMA(DIFF,M);
MACD:=2*(DIFF-DEA),COLORSTICK;
MID:MA(CLOSE,N),COLORMAGENTA;
TMP2:=STD(CLOSE,W);
TOP:MID+P*TMP2,COLORMAGENTA;
BOTTOM:MID-P*TMP2,COLORMAGENTA;
COND1:MA(C,60)>REF(MA(C,60),1)&&DIFF>0&&DEA>0&&2*(DIFF-DEA)>0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1);
COND2:MA(C,60)<REF(MA(C,60),1)&&DIFF<0&&DEA<0&&2*(DIFF-DEA)<0&&TOP>REF((MID+P*TMP2),1)&&BOTTOM<REF((MID-P*TMP2),1);
DRAWICON(CROSS(COND1,0.5),H,'ICO1');
DRAWICON(CROSS(COND2,0.5),H,'ICO2');
COND1,BK;
COND2,SK;
C<A,SP;
C>A,BP;
CHECKSIG(SP,'A',0,'C',0,0);
CHECKSIG(BP,'A',0,'C',0,0);
AUTOFILTER;
有思路,想编写各种指标公式,程序化交易模型,选股公式,预警公式的朋友
可联系技术人员 QQ: 511411198 进行 有偿 编写!(不贵!点击查看价格!)
相关文章
-
没有相关内容