各位大大能否解答一下,多週期KD是不是有問題?
setbarfreq("D");
setTOtalBar(40);
input: Length(5), RSVt(3), Kt(3);
variable: rsv(0), k(0), _d(0);
variable:rsv_w(0), kk_w(0), dd_w(0);
variable: rsv_m(0), kk_m(0), dd_m(0);
Stochastic("D",Length, RSVt, Kt, rsv, k, _d);
xf_stochastic("W", 9, 3, 3, rsv_w, kk_w, dd_w);
xf_stochastic("M", 9, 3, 3, rsv_m, kk_m, dd_m);
condition1= k cross Over _d;
condition3=kk_w > dd_w and kk_m > dd_m
condition4=volume>volume[1]*1.5
and (volume>average(volume,5)or volume>average(volume,60));
condition5=close>close[1]*1.02;
if condition1 and condition3 and condition4 and condition5
then ret=1;
outputField1(kk_w,2,"周K");
outputField2(dd_w,2,"周d");
 
 
             
        
         
         
         
     
     分類
    分類
 
            
6 評論