SuanShu, a Java numerical and statistical library

com.numericalmethod.suanshu.stats.timeseries
Interface TimeSeries<T,V>

All Known Subinterfaces:
MultiVariateRealization, MultiVariateRealization, MultiVariateTimeSeries<T>, MultiVariateTimeSeries, Realization, Realization, TimeSeries<T>, TimeSeries
All Known Implementing Classes:
AdditiveModel, ArimaSim, ArimaSim, GarchSim, GenericTimeTimeSeries, GenericTimeTimeSeries, MultiplicativeModel, OneDimensionTimeSeries, RandomWalk.MultiVariateRealization, RandomWalk.Realization, SimpleMultiVariateTimeSeries, SimpleTimeSeries

public interface TimeSeries<T,V>

A time series is an serially indexed collection of items. Time series data have a natural temporal ordering. This makes time series analysis distinct from other common data analysis problems, in which there is no natural ordering of the observations. A time series model will generally reflect the fact that observations close together in time will be more closely related than observations further apart. In addition, time series models will often make use of the natural one-way ordering of time so that values for a given period will be expressed as deriving in some way from past values, rather than from future values.

In our implementation, we represent each datum and its timestamp as a pair of value and index often called time. The entries/pairs are sorted in ascending order by the timestamps, c.f., TimeSeries.Entry.

Also, a time series is a real-only structure once it is created. It is read using an TimeSeries.Iterator. Different implementations of a time series have their own implementations of the iterators.

See Also:
Wikipedia: Time series

Nested Class Summary
static class TimeSeries.Entry<T,V>
          A time series is composed of a sequence of Entrys.
static class TimeSeries.Iterator<E extends TimeSeries.Entry<?,?>>
          the Iterator to read a time series This class provides a default implementation of an Iterator for subclasses to override.
 
Method Summary
 TimeSeries.Iterator<? extends TimeSeries.Entry<T,V>> iterator()
          Get an iterator to read this time series.
 int size()
          the length of the time series
 

Method Detail

iterator

TimeSeries.Iterator<? extends TimeSeries.Entry<T,V>> iterator()
Get an iterator to read this time series.

Returns:
an iterator

size

int size()
the length of the time series

Returns:
the size

SuanShu, a Java numerical and statistical library

Copyright © 2011 Numerical Method Inc. Ltd. All Rights Reserved.