The resource loading... loading...

TA.RSI

The TA.RSI() function is used to calculate the Strength Indicator.

The return value of the TA.RSI() function is: a one-dimensional array. array

TA.RSI(inReal) TA.RSI(inReal, optInTimePeriod)

The inReal parameter is used to specify the K-line data. inReal true {@struct/Record Record} structure arrays, numeric arrays The optInTimePeriod parameter is used to set the period. optInTimePeriod false number

function main(){
    var records = exchange.GetRecords(PERIOD_M30)
    var rsi = TA.RSI(records, 14)
    Log(rsi)
}
def main():
    r = exchange.GetRecords(PERIOD_M30)
    rsi = TA.RSI(r, 14)
    Log(rsi)
void main() {
    auto r = exchange.GetRecords(PERIOD_M30);
    auto rsi = TA.RSI(r, 14);
    Log(rsi); 
}

The default value of the optInTimePeriod parameter of the TA.RSI() function is: 14.

{@fun/TA/TA.MACD TA.MACD}, {@fun/TA/TA.KDJ TA.KDJ}, {@fun/TA/TA.ATR TA.ATR}, {@fun/TA/TA.OBV TA.OBV}, {@fun/TA/TA.MA TA.MA}, {@fun/TA/TA.EMA TA.EMA}, {@fun/TA/TA.BOLL TA.BOLL}, {@fun/TA/TA.Alligator TA.Alligator}, {@fun/TA/TA.CMF TA.CMF}, {@fun/TA/TA.Highest TA.Highest}, {@fun/TA/TA.Lowest TA.Lowest}

TA.KDJ TA.ATR