|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Interface for a stores a time series of data collected during the partial interval (start,end]
In the case of data measured over a subinterval
the endpoint of the subinterval must lie in (start,end]
If interval straddles both start and end then it is also included.
Used by domain specific wrappers like net.agmodel.weatherData
interval data
start______________end
v v
----|===== =====|----
|=====| |-----|
|=======================|
---- excluded data
==== included data
point data
start______________end
v v
. . OOOOOO OO...
... excluded data
OOO included data
| Method Summary | |
Store |
averageStore(Duration newResolution)
Creates a new store with data averaged to a lower temporal resolution. |
Store |
averageStore(Duration newResolution,
String newName)
Creates a new store with data averaged to a lower temporal resolution. |
Store |
extendStore(Date newEnd)
Creates a new store with a copy of the same data covering a longer period. |
Store |
extendStore(Interval interval)
Creates a new store at the same resolution as this one but covering a different DateRange. |
JigsawQuantity |
getAverage(Interval interval)
Returns the average value of the time series over the interval. |
float[] |
getCoverage()
Creates an array representing the coverage of the data returned by getData(). |
double[] |
getData()
Creates an array containing the data from the store. |
JigsawQuantity |
getInstant(Date time)
Returns the instantaneous value of the time series at a particular point in time. |
JigsawQuantity |
getMaximum(Interval interval)
Returns the maximum value of the time series over the interval. |
JigsawQuantity |
getMinimum(Interval interval)
Returns the minimum value of the time series over the interval. |
double |
getNumberOfValues()
Returns the number of data values in the store |
SummaryHistory |
getSummaryHistory()
Returns the summary history for the data stored in the sequence |
JigsawQuantity |
getTotal(Interval interval)
Returns the total value of the sequence over the interval. |
Store |
maximumStore(Duration newResolution)
Creates a new store containing data summarised by finding the maximum of each subrange. |
Store |
maximumStore(Duration newResolution,
String newName)
Creates a new store containing data summarised by finding the maximum of each subrange. |
Store |
minimumStore(Duration newResolution)
Creates a new store containing data summarised by finding the minimum of each subrange. |
Store |
minimumStore(Duration newResolution,
String newName)
Creates a new store containing data summarised by finding the minimum of each subrange. |
void |
putInstantValue(Date time,
double value)
Records the instantaneous value of the time series at a particular time |
void |
putValueOverInterval(Interval interval,
double value)
Records the value of the timeseries over some subinterval. |
void |
putValueOverInterval(Interval interval,
JigsawQuantity value)
Records the value of the timeseries over some subinterval, its coverage, and the extent to which it was interpolated. |
Store |
sampleStore(Duration newResolution)
Creates a new store with data sampled to a lower temporal resolution. |
Store |
sampleStore(Duration newResolution,
String newName)
Creates a new store with data sampled to a lower temporal resolution. |
Store |
totalStore(Duration newResolution)
Creates a new store with data totalled to a lower temporal resolution. |
Store |
totalStore(Duration newResolution,
String newName)
Creates a new store with data totalled to a lower temporal resolution. |
| Methods inherited from interface net.agmodel.physical.Sequence |
clone, dumpSequence, getColumnHeading, getContentsAsString, getCurrentResolution, getDateRange, getName, getNumberOfSubComponents, getResolution, getSequenceHeading, getSubHeading, getSummaryKind, getUnitsHeading, setColumnHeading, setName |
| Method Detail |
public void putInstantValue(Date time,
double value)
time - the point in timevalue - the value of the time series at that time
IllegalArgumentException - if the time is outside the interval that the period is intended to store
public void putValueOverInterval(Interval interval,
double value)
interval - the period of time over which the measurement was taken. Interval duration must a postive integer multiple of store resolution, and the interval must align with the store "cells".value - the value of the time series over that interval
IllegalArgumentException - if the subinterval is outside the interval declared when the store was constructed
public void putValueOverInterval(Interval interval,
JigsawQuantity value)
interval - the period of time over which the measurement was taken. Interval duration must a positive integer multiple of store resolution, and the interval must align with the store "cells".value - the value of the time series over that interval as a JigsawQuantity
IllegalArgumentException - if the subinterval is outside the interval declared when the store was constructedpublic JigsawQuantity getInstant(Date time)
public JigsawQuantity getAverage(Interval interval)
public JigsawQuantity getMinimum(Interval interval)
public JigsawQuantity getMaximum(Interval interval)
public JigsawQuantity getTotal(Interval interval)
public Store totalStore(Duration newResolution)
newResolution - the resolution of the resulting sequence
public Store totalStore(Duration newResolution,
String newName)
newResolution - the resolution of the resulting sequencenewName - the new name for the store
public Store averageStore(Duration newResolution)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequence
public Store averageStore(Duration newResolution,
String newName)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequencenewName - the new name for the store
public Store minimumStore(Duration newResolution)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequence
public Store minimumStore(Duration newResolution,
String newName)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequencenewName - the new name for the store
public Store maximumStore(Duration newResolution)
totalStore(Duration) for information on how the first data value is handled.
The new store's default name is provided by SummaryKind.MAXIMUM.getName().
newResolution - the resolution of the resulting sequence
public Store maximumStore(Duration newResolution,
String newName)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequencenewName - the new name for the store
public Store sampleStore(Duration newResolution)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequence
public Store sampleStore(Duration newResolution,
String newName)
totalStore(Duration) for information on how the first data value is handled.
newResolution - the resolution of the resulting sequencenewName - the new name for the store
public Store extendStore(Interval interval)
interval - the interval that the new store covers.
public Store extendStore(Date newEnd)
newEnd - the new end date, later than the current end date;
IllegalArgumentException - if newEnd is earlier or the same as the current end.public SummaryHistory getSummaryHistory()
public double[] getData()
getCoverage() to test for the coverage.
(Missing values are returned as Double.NaN at present, but this might change.)
public float[] getCoverage()
getData().
public double getNumberOfValues()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||