比较sharpe率指标,用于股性判定,看看其股价与交易面超买超卖 SHN:=3;
LON:=21;
YN:=244;
L0:0,colorblack ,POINTDOT;
L1:10 ,colorblack ,POINTDOT;
L2:20 ,colorblack ,POINTDOT;
L3:30 ,colorblack ,POINTDOT;
SM:=MA(C,SHN);
LM:=MA(C,LON);
MAXRR:=SUM(IF(SM>LM,(C-REF(C,1))/REF(C,1),0),YN);
YBD:=STD((C-REF(C,1))/REF(C,1),YN);
SHARP:MAXRR/YBD, colorred,LINETHICK1;
SHN2:=7;//www.fxjgsw.com
LON2:=55;
SM2:=MA(C,SHN2);
LM2:=MA(C,LON2);
MAXRR2:=SUM(IF(SM2>LM2,(C-REF(C,1))/REF(C,1),0),YN);
SHARP2:MAXRR2/YBD,colorblue,LINETHICK1;
SHN3:=3;
LON3:=13;
SM3:=MA(C,SHN3);
LM3:=MA(C,LON3);
MAXRR3:=SUM(IF(SM3>LM3,(C-REF(C,1))/REF(C,1),0),YN);
SHARP3:MAXRR3/YBD,colormagenta,LINETHICK1;
SHNV:=3;
LONV:=21;
SMV:=MA(AMOUNT,SHNV);
LMV:=MA(AMOUNT,LONV);
YBDV:=STD((AMOUNT-REF(AMOUNT,1))/REF(AMOUNT,1),YN);
MAXRRV:=SUM(IF(SMV>LMV,(AMOUNT -REF(AMOUNT,1))/REF(AMOUNT,1),0),YN);
SHARPV:MAXRRV/YBDV, coloryellow,LINETHICK1;
|
