question: protected void initForecastErrors ( ArrayList < Float > model , TimeSeries . DataSequence data ) { double sumErr = 0.0 ; double sumAbsErr = 0.0 ; double sumAbsPercentErr = 0.0 ; double sumErrSquared = 0.0 ; int processedPoints = 0 ; int n = data . size ( ) ; for ( int i = 0 ; i < n ; i ++ ) { double error = model . get ( i ) - data . get ( i ) . value ; sumErr += error ; sumAbsErr += Math . abs ( error ) ; sumAbsPercentErr += Math . abs ( error / data . get ( i ) . value ) ; sumErrSquared += error * error ; processedPoints ++ ; } this . bias = sumErr / processedPoints ; this . mad = sumAbsErr / processedPoints ; this . mape = sumAbsPercentErr / processedPoints ; this . mse = sumErrSquared / processedPoints ; this . sae = sumAbsErr ; errorsInit = true ; }
target:  Initializes all errors given the model.