Class DifferencedIntTimeTimeSeries
- java.lang.Object
-
- dev.nm.stat.timeseries.datastructure.univariate.realtime.inttime.DifferencedIntTimeTimeSeries
-
- All Implemented Interfaces:
TimeSeries<Integer,Double,IntTimeTimeSeries.Entry>,IntTimeTimeSeries,UnivariateTimeSeries<Integer,IntTimeTimeSeries.Entry>,Iterable<IntTimeTimeSeries.Entry>
public class DifferencedIntTimeTimeSeries extends Object implements IntTimeTimeSeries
Differencing of a time series xt in discrete time t is the transformation of the series to a new time series (1-B)xt where the new values are the differences between consecutive values of xt. This procedure may be applied consecutively more than once, giving rise to the "first differences", "second differences", etc. An d-th order differencing gives arise to a new time series (1-B)dxt.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface dev.nm.stat.timeseries.datastructure.univariate.realtime.inttime.IntTimeTimeSeries
IntTimeTimeSeries.Entry
-
-
Constructor Summary
Constructors Constructor Description DifferencedIntTimeTimeSeries(IntTimeTimeSeries xt, int d)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description doubleget(int t)Get the value at timet.Iterator<IntTimeTimeSeries.Entry>iterator()intsize()Get the length of the time series.double[]toArray()Convert this time series into an array, discarding the timestamps.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Constructor Detail
-
DifferencedIntTimeTimeSeries
public DifferencedIntTimeTimeSeries(IntTimeTimeSeries xt, int d)
-
-
Method Detail
-
get
public double get(int t)
Description copied from interface:IntTimeTimeSeriesGet the value at timet.- Specified by:
getin interfaceIntTimeTimeSeries- Parameters:
t- a time index, counting from 1- Returns:
- the value at time
t
-
toArray
public double[] toArray()
Description copied from interface:UnivariateTimeSeriesConvert this time series into an array, discarding the timestamps.- Specified by:
toArrayin interfaceUnivariateTimeSeries<Integer,IntTimeTimeSeries.Entry>- Returns:
- the array representation of the time series
-
size
public int size()
Description copied from interface:TimeSeriesGet the length of the time series.- Specified by:
sizein interfaceTimeSeries<Integer,Double,IntTimeTimeSeries.Entry>- Returns:
- the time series length
-
iterator
public Iterator<IntTimeTimeSeries.Entry> iterator()
- Specified by:
iteratorin interfaceIterable<IntTimeTimeSeries.Entry>
-
-