public double getDoubleValue() { return this.getValue(); }
public double getDoubleValue() { return this.getValue(); }
private void calculateAndDeliverAggregationValue(final AggregationVariableSet variables) { final double aggregationValue; final NamedDoubleTimeSeriesPoint tsPoint; synchronized (this) { final int listSize = variables.getAggregationList().size(); final double[] a = new double[listSize]; for (int i = 0; i < listSize; i++) { a[i] = variables.getAggregationList().get(i).getValue(); } aggregationValue = this.aggregationMethod.getAggregationValue(a); tsPoint = new NamedDoubleTimeSeriesPoint(variables.getLastTimestampInCurrentInterval(), aggregationValue, variables.getAggregationList().get(0).getName()); // use name of first element (any will do) variables.getAggregationList().clear(); } super.deliver(OUTPUT_PORT_NAME_AGGREGATED_TSPOINT, tsPoint); }
private void calculateAndDeliverAggregationValue(final AggregationVariableSet variables) { final double aggregationValue; final NamedDoubleTimeSeriesPoint tsPoint; synchronized (this) { final int listSize = variables.getAggregationList().size(); final double[] a = new double[listSize]; for (int i = 0; i < listSize; i++) { a[i] = variables.getAggregationList().get(i).getValue(); } aggregationValue = this.aggregationMethod.getAggregationValue(a); tsPoint = new NamedDoubleTimeSeriesPoint(variables.getLastTimestampInCurrentInterval(), aggregationValue, variables.getAggregationList().get(0).getName()); // use name of first element (any will do) variables.getAggregationList().clear(); } super.deliver(OUTPUT_PORT_NAME_AGGREGATED_TSPOINT, tsPoint); }
private NamedDoubleTimeSeriesPoint calculateAggregationValueOfCurrentInterval(final AggregationVariableSet variables, final String name) { final double aggregationValue; final NamedDoubleTimeSeriesPoint tsPoint; final long firstTimestampInCurrentInterval = variables.getFirstTimestampInCurrentInterval(); final long lastTimestampInCurrentInterval = variables.getLastTimestampInCurrentInterval(); synchronized (this) { final int listSize = variables.getAggregationList().size(); if (listSize <= 0) { tsPoint = new NamedDoubleTimeSeriesPoint(lastTimestampInCurrentInterval, Double.NaN, name); } else { final double[] a = new double[listSize]; for (int i = 0; i < listSize; i++) { a[i] = variables.getAggregationList().get(i).getValue(); } aggregationValue = this.aggregationMethod.getAggregationValue(a); tsPoint = new NamedDoubleTimeSeriesPoint(lastTimestampInCurrentInterval, aggregationValue, name); variables.getAggregationList().clear(); } variables.setFirstTimestampInCurrentInterval(firstTimestampInCurrentInterval + this.aggregationSpan); variables.setLastTimestampInCurrentInterval(lastTimestampInCurrentInterval + this.aggregationSpan); } return tsPoint; }
currentWindow.append(input.getValue()); name, forecast, input.getValue(), timestamp, result.getConfidenceLevel(), result.getMeanAbsoluteScaledError()); if (AbstractAnalysisComponent.LOGGER.isDebugEnabled()) { AbstractAnalysisComponent.LOGGER.debug("Forecast: " + forecast + ", Measurement: " + input.getValue() + ", MASE: " + result.getMeanAbsoluteScaledError()); name, result.getForecast().getPoints().get(0).getValue(), input.getValue(), timestamp, result.getConfidenceLevel(),
private NamedDoubleTimeSeriesPoint calculateAggregationValueOfCurrentInterval(final AggregationVariableSet variables, final String name) { final double aggregationValue; final NamedDoubleTimeSeriesPoint tsPoint; final long firstTimestampInCurrentInterval = variables.getFirstTimestampInCurrentInterval(); final long lastTimestampInCurrentInterval = variables.getLastTimestampInCurrentInterval(); synchronized (this) { final int listSize = variables.getAggregationList().size(); if (listSize <= 0) { tsPoint = new NamedDoubleTimeSeriesPoint(lastTimestampInCurrentInterval, Double.NaN, name); } else { final double[] a = new double[listSize]; for (int i = 0; i < listSize; i++) { a[i] = variables.getAggregationList().get(i).getValue(); } aggregationValue = this.aggregationMethod.getAggregationValue(a); tsPoint = new NamedDoubleTimeSeriesPoint(lastTimestampInCurrentInterval, aggregationValue, name); variables.getAggregationList().clear(); } variables.setFirstTimestampInCurrentInterval(firstTimestampInCurrentInterval + this.aggregationSpan); variables.setLastTimestampInCurrentInterval(lastTimestampInCurrentInterval + this.aggregationSpan); } return tsPoint; }
currentWindow.append(input.getValue()); name, forecast, input.getValue(), timestamp, result.getConfidenceLevel(), result.getMeanAbsoluteScaledError()); if (AbstractAnalysisComponent.LOG.isDebugEnabled()) { AbstractAnalysisComponent.LOG.debug("Forecast: " + forecast + ", Measurement: " + input.getValue() + ", MASE: " + result.getMeanAbsoluteScaledError()); name, result.getForecast().getPoints().get(0).getValue(), input.getValue(), timestamp, result.getConfidenceLevel(),