Represents a single dated observation: a value at a point in time, with an index used as the independent variable for forecasting. Used both as a line chart data point via ChartManager.ChartBuilder.addXY(Date, Number) and as the observation type shared by RegressionBuilder, ForecastModel and AnomalyDetectionModel. A point produced by ForecastModel.predictions() has isPredicted() set to true rather than being an actual observation.

Implements: DataPoint, DataPoint


Properties

PropertyReturnsDescription
dateDateDate this observation was recorded at, or the forecast period's date for a predicted point.
dependentValuedoubleValue of this point, as required by openforecast's DataPoint interface; equivalent to getValue().
independentVariableNamesString[]Names of the independent variables used by openforecast when fitting a model against this point. Always a single-element array, since only one independent variable ("x") is used.
predictedbooleanWhether this point is a forecast produced by ForecastModel.predictions(), rather than an actual observation.
valuedoubleObserved value at this point, or the forecast value for a predicted point.

Methods

getDate()

Returns: Date

Date this observation was recorded at, or the forecast period's date for a predicted point.

getValue()

Returns: double

Observed value at this point, or the forecast value for a predicted point.

getDependentValue()

Returns: double

Value of this point, as required by openforecast's DataPoint interface; equivalent to getValue().

getIndependentVariableNames()

Returns: String[]

Names of the independent variables used by openforecast when fitting a model against this point. Always a single-element array, since only one independent variable ("x") is used.

isPredicted()

Returns: boolean

Whether this point is a forecast produced by ForecastModel.predictions(), rather than an actual observation.

To get full access to the Kademi Hub existing customers can login here, or new customers can register here.