P:=13;
LC := REF(CLOSE,1);
RSI:SMA(MAX(CLOSE-LC,0),P,1)/SMA(ABS(CLOSE-LC),P,1)*100,COLORyellow,LINETHICK2;
峰顶: HHV(MA(RSI,3),P),COLORFF00FF;
谷底:LLV(MA(RSI,3),P),COLORFF8800;
{www.gupang.com 股旁网_飞狐股票指标公式}
地平:(HHV(MA(RSI,3),P)+LLV(MA(RSI,3),P))/2,COLORFFFFFF,LINETHICK2;
FILLRGN(rsi>峰顶,rsi,峰顶),colorred;
FILLRGN(rsi<谷底,rsi,谷底),colorgreen;