public class TimeSeries extends java.lang.Object implements TsIterable, ProcessingChainNode
Time interval between values is constant
Modifier and Type | Field and Description |
---|---|
float[][] |
data
time series data values:
data [ sensor index ] [ row index ]
|
boolean[][] |
dataInterpolated |
DataQuality[][] |
dataQuality |
boolean |
hasDataInterpolatedFlag |
boolean |
hasDataQualityFlag |
java.lang.String[] |
parameterNames
sensor names of time series in data
|
long |
startTimestamp
timestamp of first entry in data
|
int |
timeStep
constant time step between entries
|
Constructor and Description |
---|
TimeSeries(ProcessingChainSupplier processingChainSupplier,
java.lang.String[] parameterNames,
long startTimestamp,
int timeStep,
float[][] data,
DataQuality[][] dataQuality,
boolean[][] dataInterpolated)
Creates TimeSeries filled with data.
|
Modifier and Type | Method and Description |
---|---|
void |
addToProcessingChain(ProcessingChainEntry entry) |
void |
addToProcessingChain(java.lang.String entry) |
boolean |
containsParamterName(java.lang.String parameterName) |
static TimeSeries |
create(TsIterator input_iterator)
Converts elements of an iterator in TimeSeries object.
|
TsSchema |
createSchema() |
long |
getFirstTimestamp()
get timestamp of first data entry
|
boolean[] |
getInterpolationFlags(java.lang.String parameterName) |
long |
getLastTimestamp()
get timestamp of last data entry
|
int |
getParameterNameIndex(java.lang.String parameterName)
get position of sensor name in data array
|
ProcessingChain |
getProcessingChain()
Default implementation: Get processing chain with this as source entry.
|
float[] |
getValues(java.lang.String parameterName)
get one data column
|
TsIterator |
timeSeriesIteratorCLIP(java.lang.Long clipStart,
java.lang.Long clipEnd)
Iterator of data from clipStart to clipEnd
|
static TimeSeries |
toBaseTimeSeries(java.lang.Long startTimestamp,
java.lang.Long endTimestamp,
TimestampSeries timestampSeries)
converts TimestampSeries to TimeSeries
missing values before and after data in source time series and gaps within source timeseries are filled with NaN-values
source time series needs to be aggregated already
|
java.lang.String |
toString()
some summary data of this time series
|
TsIterator |
tsIterator() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
iterator
getProcessingTitle
createUnknown, of
createUnknown
public java.lang.String[] parameterNames
public long startTimestamp
public final int timeStep
public float[][] data
public boolean hasDataQualityFlag
public boolean hasDataInterpolatedFlag
public DataQuality[][] dataQuality
public boolean[][] dataInterpolated
public TimeSeries(ProcessingChainSupplier processingChainSupplier, java.lang.String[] parameterNames, long startTimestamp, int timeStep, float[][] data, DataQuality[][] dataQuality, boolean[][] dataInterpolated)
processingChainSupplier
- nullableparameterNames
- column namesstartTimestamp
- timestampm of first entrytimeStep
- time step between entriesdata
- Array of data rows.dataQuality
- Array of data quality rows. nullabledataInterpolated
- Array of data interpolated flag rows. nullablepublic static TimeSeries create(TsIterator input_iterator)
Elements need to be ordered in constant timeStep time intervals.
input_iterator
- public static TimeSeries toBaseTimeSeries(java.lang.Long startTimestamp, java.lang.Long endTimestamp, TimestampSeries timestampSeries)
startTimestamp
- timestamp of first entry in resulting time seriesendTimestamp
- timestamp of last entry in resulting time seriestimestampSeries
- public java.lang.String toString()
toString
in class java.lang.Object
public int getParameterNameIndex(java.lang.String parameterName)
parameterName
- public boolean containsParamterName(java.lang.String parameterName)
public float[] getValues(java.lang.String parameterName)
parameterName
- public boolean[] getInterpolationFlags(java.lang.String parameterName)
public long getFirstTimestamp()
public long getLastTimestamp()
public TsIterator tsIterator()
tsIterator
in interface TsIterable
public TsIterator timeSeriesIteratorCLIP(java.lang.Long clipStart, java.lang.Long clipEnd)
clipStart
- if null then from startclipEnd
- if null then up to endpublic TsSchema createSchema()
public ProcessingChain getProcessingChain()
ProcessingChainNode
getProcessingChain
in interface ProcessingChainNode
getProcessingChain
in interface ProcessingChainSupplier
public void addToProcessingChain(java.lang.String entry)
public void addToProcessingChain(ProcessingChainEntry entry)