-- 作者:OscarDeng
-- 发布时间:2019/7/11 19:35:36
-- 为什么编译会说底背离DAY未定义?
DIFFDAY:STKINDI(\'SH000001\',\'MACDViolate.DIFF(12,26,9)\',0,6,-1); DIFF60MIN:STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,5,-1); DIFF15MIN:STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,3,-1); DIFF5MIN:STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,2,-1); DIFF1MIN:STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,1,-1); DEA1MIN:STKINDI(\'SH000001\',\'MACDVIOLATE.DEA(12,26,9)\',0,1,-1); //POSITIVEV 代表底背离POSITIVE VIOLATION 底背离5MIN1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,2,-1); 底背离5MIN2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,2,-1); 底背离5MIN3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,2,-1); 底背离5MIN4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,2,-1); 底背离5MIN5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,2,-1);
底背离15MIN1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,3,-1); 底背离15MIN2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,3,-1); 底背离15MIN3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,3,-1); 底背离15MIN4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,3,-1); 底背离15MIN5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,3,-1);
底背离60MIN1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,5,-1); 底背离60MIN2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,5,-1); 底背离60MIN3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,5,-1); 底背离60MIN4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,5,-1); 底背离60MIN5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,5,-1);
底背离DAY1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,6,-1); 底背离DAY2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,6,-1); 底背离DAY3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,6,-1); 底背离DAY4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,6,-1); 底背离DAY5:=STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,6,-1);
底背离5MIN:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,2,-1); 底背离15MIN:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,3,-1); 底背离60MIN:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,5,-1); 底背离DAY:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,6,-1);
POSITIVE5MIN:底背离5MIN||底背离15MIN||底背离60MIN||底背离DAY; POSITIVE15MIN:底背离5MIN2||底背离5MIN3||底背离5MIN4||底背离5MIN5||底背离15MIN||底背离60MIN||底背离DAY; POSITIVE60MIN:底背离5MIN5||底背离15MIN2||底背离15MIN3||底背离15MIN4||底背离15MIN5||底背离60MIN||底背离DAY; POSITIVEDAY:底背离15MIN4||底背离15MIN5||底背离60MIN2||底背离60MIN3||底背离60MIN4||底背离60MIN5||底背离DAY; POSITIVEDAY2:底背离DAY5||底背离DAY4||底背离DAY3||底背离DAY2;
|
-- 作者:OscarDeng
-- 发布时间:2019/7/12 12:38:50
-- 还有一个为什么POSITIVE5MIN, DIFF60MIN 等这些都能显示出来, 但是底背离1MIN 到 底背离PV60MIN 都显示不出来
还有一个为什么POSITIVE5MIN, DIFF60MIN 等这些都能显示出来, 但是底背离1MIN 到 底背离PV60MIN 都显示不出来, 把底背离三个字换成PV后也照样显示不出来数值, 就是了个是什么原因? 连AA也显示不出数值
DIFFDAY:=STKINDI(\'SH000001\',\'MACDViolate.DIFF(12,26,9)\',0,6,-1); DIFF60MIN:=STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,5,-1); DIFF15MIN:=STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,3,-1); DIFF5MIN:=STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,2,-1); DIFF1MIN:=STKINDI(\'SH000001\',\'MACDVIOLATE.DIFF(12,26,9)\',0,1,-1); DEA1MIN:=STKINDI(\'SH000001\',\'MACDVIOLATE.DEA(12,26,9)\',0,1,-1); //POSITIVEV 代表底背离POSITIVE VIOLATION,PV PV5MIN1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,2,-1); PV5MIN2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,2,-1); PV5MIN3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,2,-1); PV5MIN4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,2,-1); PV5MIN5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,2,-1);
PV15MIN1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,3,-1); PV15MIN2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,3,-1); PV15MIN3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,3,-1); PV15MIN4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,3,-1); PV15MIN5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,3,-1);
PV60MIN1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,5,-1); PV60MIN2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,5,-1); PV60MIN3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,5,-1); PV60MIN4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,5,-1); PV60MIN5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,5,-1);
PVDAY1:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离1(12,26,9)\',0,6,-1); PVDAY2:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离2(12,26,9)\',0,6,-1); PVDAY3:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离3(12,26,9)\',0,6,-1); PVDAY4:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离4(12,26,9)\',0,6,-1); PVDAY5:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离5(12,26,9)\',0,6,-1);
PV5MIN:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,2,-1); PV15MIN:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,3,-1); PV60MIN:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,5,-1); PVDAY6:STKINDI(\'SH00001\',\'MACDVIOLATE.底背离(12,26,9)\',0,6,-1);
POSITIVEV5MIN:=PV5MIN||PV15MIN||PV60MIN||PVDAY6; POSITIVEV15MIN:=PV5MIN2||PV5MIN3||PV5MIN4||PV5MIN5||PV15MIN||PV60MIN||PVDAY6; POSITIVEV60MIN:=PV5MIN5||PV15MIN2||PV15MIN3||PV15MIN4||PV15MIN5||PV60MIN||PVDAY6; POSITIVEVDAY:=PV15MIN4||PV15MIN5||PV60MIN2||PV60MIN3||PV60MIN4||PV60MIN5||PVDAY6; POSITIVEVDAY2:=PVDAY5||PVDAY4||PVDAY3||PVDAY2; AA:PV5MIN1;
|
-- 作者:OscarDeng
-- 发布时间:2019/7/12 21:55:32
-- 我用下面语句调用下面的技术指标, 同样的, DEA1MIN 就可以显示, 但是CC就显示不出来,
我自己也做了个测试, 我用下面语句调用下面的技术指标, 同样的, DEA1MIN 就可以显示, 但是CC就显示不出来, 不会是逻辑判断语句就不允许显示出来吧? 在文华8从来不会出现这些问题。 但是用了金字塔后发现很多莫名奇怪的原因。
DEA1MIN:STKINDI(\'SH000001\',\'test1.DEA(12,26,9)\',0,1,-1); PV5MIN1:STKINDI(\'SH00001\',\'test1.CC(12,26,9)\',0,1,-1);
被调用技术指标
DIFF :EMA(CLOSE,SHORT) - EMA(CLOSE,LONG); DEA :EMA(DIFF,M); MACD:2*(DIFF-DEA),COLORSTICK; MACDMAX:=MAX(C,O); MACDMIN:=MIN(C,O); MACDL:=LLV(MACDMIN,7);//8周期内最低收盘价
DIFFL:=(LLV(DIFF,7)+REF(DIFF,LLVBARS(DIFF,7)-1)+REF(DIFF,LLVBARS(DIFF,7)+1))/3;//4天到8周期的最低DIFF GTMIN:=DEA>REF(DEA,1) AND REF(DEA,1)<REF(DEA,2) && DEA<0;//找DEA是最低的 A1:=BARSLAST(REF(GTMIN,1));//A1底背离,最低转折点到今天的周期数, 转折点单根K线为0 A2:=A1+REF(A1,A1+1); A3:=A2+REF(A1,A2+2); A4:=A3+REF(A1,A3+3); A5:=A4+REF(A1,A4+4); IGNOREMIN1:=ABS( REF(DIFFL,A1+1)/DIFFL/( MACDL/REF(MACDL,A1+1)) )>1.06; IGNOREMIN2:=ABS( REF(DIFFL,A2+1)/DIFFL/( MACDL/REF(MACDL,A2+1)) )>1.06; IGNOREMIN3:=ABS( REF(DIFFL,A3+1)/DIFFL/( MACDL/REF(MACDL,A4+1)) )>1.06; IGNOREMIN4:=ABS( REF(DIFFL,A4+1)/DIFFL/( MACDL/REF(MACDL,A4+1)) )>1.06; IGNOREMIN5:=ABS( REF(DIFFL,A5+1)/DIFFL/( MACDL/REF(MACDL,A5+1)) )>1.06; CC:(REF(MACDL,A1+1)-MACDL)/MACDL>=-0.01 AND (DIFFL-REF(DIFFL,A1+1))>=0 AND GTMIN AND IGNOREMIN1;
|