CS1:=(CLOSE-LLV(LOW,243))/(HHV(HIGH,243)-LLV(LOW,243))*100;
DDFX1:=(SMA(CS1,3,1)-50)*2;
DCS1:=(INDEXC-LLV(INDEXL,243))/(HHV(INDEXH,243)-LLV(INDEXL,243))*100;
禪1:=(SMA(DCS1,3,1)-50)*2;
差值1:=DDFX1-禪1;
CS2:=(CLOSE-LLV(LOW,144))/(HHV(HIGH,144)-LLV(LOW,144))*100;
DDFX2:=(SMA(CS2,3,1)-50)*2;
DCS2:=(INDEXC-LLV(INDEXL,144))/(HHV(INDEXH,144)-LLV(INDEXL,144))*100;
禪2:=(SMA(DCS2,3,1)-50)*2;
差值2:=DDFX2-禪2;
CS3:=(CLOSE-LLV(LOW,89))/(HHV(HIGH,89)-LLV(LOW,89))*100;
DDFX3:=(SMA(CS3,3,1)-50)*2;
DCS3:=(INDEXC-LLV(INDEXL,89))/(HHV(INDEXH,89)-LLV(INDEXL,89))*100;
禪3:=(SMA(DCS3,3,1)-50)*2;
差值3:=DDFX3-禪3;
CS4:=(CLOSE-LLV(LOW,55))/(HHV(HIGH,55)-LLV(LOW,55))*100;
DDFX4:=(SMA(CS4,3,1)-50)*2;
DCS4:=(INDEXC-LLV(INDEXL,55))/(HHV(INDEXH,55)-LLV(INDEXL,55))*100;
禪4:=(SMA(DCS4,3,1)-50)*2;
差值4:=DDFX4-禪4;
CS5:=(CLOSE-LLV(LOW,34))/(HHV(HIGH,34)-LLV(LOW,34))*100;
DDFX5:=(SMA(CS5,3,1)-50)*2;
DCS5:=(INDEXC-LLV(INDEXL,34))/(HHV(INDEXH,34)-LLV(INDEXL,34))*100;
禪5:=(SMA(DCS5,3,1)-50)*2;
差值5:=DDFX5-禪5;
CS6:=(CLOSE-LLV(LOW,21))/(HHV(HIGH,21)-LLV(LOW,21))*100;
DDFX6:=(SMA(CS6,3,1)-50)*2;
DCS6:=(INDEXC-LLV(INDEXL,21))/(HHV(INDEXH,21)-LLV(INDEXL,21))*100;
禪6:=(SMA(DCS6,3,1)-50)*2;
差值6:=DDFX6-禪6;
CS7:=(CLOSE-LLV(LOW,13))/(HHV(HIGH,13)-LLV(LOW,13))*100;
DDFX7:=(SMA(CS7,3,1)-50)*2;
DCS7:=(INDEXC-LLV(INDEXL,13))/(HHV(INDEXH,13)-LLV(INDEXL,13))*100;
禪7:=(SMA(DCS7,3,1)-50)*2;
差值7:=DDFX7-禪7;
CS8:=(CLOSE-LLV(LOW,8))/(HHV(HIGH,8)-LLV(LOW,8))*100;
DDFX8:=(SMA(CS8,3,1)-50)*2;
DCS8:=(INDEXC-LLV(INDEXL,8))/(HHV(INDEXH,8)-LLV(INDEXL,8))*100;
禪8:=(SMA(DCS8,3,1)-50)*2;
差值8:=DDFX8-禪8;
DDFX差值:DDFX8-REF(DDFX8,1),NODRAW;
CS9:=(CLOSE-LLV(LOW,5))/(HHV(HIGH,5)-LLV(LOW,5))*100;
DDFX9:=(SMA(CS9,3,1)-50)*2;
跑贏大盤:(差值1+差值2+差值3+差值4+差值5+差值6+差值7+差值8)/100;
力度:跑贏大盤-REF(跑贏大盤,1);
A3:=SMA(跑贏大盤,3,1);
A5:=SMA(跑贏大盤,5,1);
A8:=SMA(跑贏大盤,8,1);
A13:=SMA(跑贏大盤,13,1);
A21:=SMA(跑贏大盤,21,1);
A34:=SMA(跑贏大盤,34,1);
A55:=SMA(跑贏大盤,55,1);
選股:((CROSS(DDFX8,-0.1) AND DDFX差值>REF(DDFX差值,1)) OR
(DDFX8>0 AND DDFX8<70 AND
DDFX差值>REF(DDFX差值,1)) OR (DDFX8>-70
AND DDFX8<=0 AND
DDFX差值>REF(DDFX差值,1))) AND
跑贏大盤>REF(跑贏大盤,1);