TimeSeries class

  • TimeSeries Class comes under the org.jfree.data.time package of the JFreeChart library.
  • This class represents a sequence of zero or more data items in the form (period, value) where 'period' is some instance of a subclass of RegularTimePeriod.

Constructor:

constructorDescription
TimeSeries(Comparable name)It creates a new (empty) time series.
TimeSeries(Comparable name, String domain, String range)It creates a new time series that contains no data.

Method Summary

MethodDescription
add(RegularTimePeriod period, double value)This method adds a new data item to the series and sends a SeriesChangeEvent to all registered listeners.
add(RegularTimePeriod period, double value, boolean notify)This method adds a new data item to the series and sends a SeriesChangeEvent to all registered listeners.
add(TimeSeriesDataItem item)This method adds a data item to the series and sends a SeriesChangeEvent to all registered listeners.
addAndOrUpdate(TimeSeries series)This method adds or updates data from one series to another.
clear( )This method removes all data items from the series and sends a SeriesChangeEvent to all registered listeners.
delete(int start, int end)This method deletes data from start until end index (end inclusive).