M:=6;//或8
VAR1:=(C+0.618*REF(C,1)+0.382*REF(C,2)+0.236*REF(C,3)+0.146*REF(C,4))/2.382;
VAR2:=HHV(C,60)-LLV(C,60);
VAR3:=(CLOSE-LLV(LOW,M))/(HHV(HIGH,M)-LLV(LOW,M))*10000;
VAR4:=SMA(MAX(VAR1-REF(VAR1,1),0),5,1)/SMA(Abs(VAR1-REF(VAR1,1)),5,1);
VAR5:=VAR1+VAR2*(VAR4-0.5);
EA反转基线:=VAR3>REF(VAR3,1) AND REF(VAR3,1)>REF(VAR3,2) AND VAR3<9000 AND VAR5