Class ExponentialMovingAverage


  • public final class ExponentialMovingAverage
    extends Object
    Exponential moving average (EMA) is a rule of thumb technique for smoothing time series data using the exponential window function (see https://fr.wikipedia.org/wiki/Moyenne_mobile)
    • Field Detail

      • first

        private boolean first
      • alpha

        private double alpha
      • average

        private double average
    • Constructor Detail

      • ExponentialMovingAverage

        public ExponentialMovingAverage​(int periods)
    • Method Detail

      • getAverage

        public double getAverage()
      • getLongAverage

        public long getLongAverage()
      • getIntAverage

        public int getIntAverage()
      • addValue

        public void addValue​(double value)