PINE LIBRARY

rate_of_change

137
Library "rate_of_change"

// description: Applies ROC algorithm to any pair of values.
// This library function is used to scale change of value (price, volume) to a percentage value, just as the ROC indicator would do. It is good practice to scale arbitrary ranges to set boundaries when you try to train statistical model.

rateOfChange(value, base, hardlimit)
  This function is a helper to scale a value change to its percentage value.
  Parameters:
    value (float)
    base (float)
    hardlimit (int)
  Returns: per: A float comprised between 0 and 100

Declinazione di responsabilità

Le informazioni ed i contenuti pubblicati non costituiscono in alcun modo una sollecitazione ad investire o ad operare nei mercati finanziari. Non sono inoltre fornite o supportate da TradingView. Maggiori dettagli nelle Condizioni d'uso.