TimeSeriesAPI » History » Version 2

Version 1 (M. Rolf, 12/16/2011 01:46 PM) → Version 2/5 (M. Rolf, 12/16/2011 02:51 PM)

h1. TimeSeriesAPI

h3. Things that sucked at old TimeSeries datatype

* Strict timestamp constraint
** Critical when appending frenquently with local-time
* No coherent abstraction for one 'entry'
* boost::ptime very expensive
* restricted to RealVectorPtr values
* attach vs. append naming (concat)
* interpolation logic fails semantically for certain data types (e.g. 'rotations')
* No iterators

h3. Things that were important in old TimeSeries datatype

* map function
* XML Serialization
* Plain file persistency
* 'logging' possible with 'local-time append'

h3. Possible Improvements

* Explicit 'local-time' append
** Append 'Generator' for timestamps (e.g. 'now' or 'plus x seconds')
* Implement Duration logic: values 'valid' for a certain time (relative)

h3. nemo::TimeSeries issues


* Vector dimensions constrainable????
* Default TimestampType pretty useless
** Use no default and switch ordering of template params <TimeStamp,Value>
* operator[] ?????
<pre>
ts = series.timestamps[index]
series.timestamps.set(index, ts)

val = series.values[index]
series.values.set(index, val)

val = series[ts]
series.set(ts, val)
</pre>
** Current 'compromiss'
** operator[] only for reading
** Split index-access into separated timestamps/values accessors
** Possible future way for write access: ReadWriteRef logic like in MathVector
<pre>
vectorSeries.values[i] = vector
vector = vectorSeries.values[i]
((Vector)vectorSeries.values[i]).vectorMember()
</pre>
** The only problem: member calls not transparently possible
<pre>
vectorSeries.values[i].vectorMember() // compile error through ReadWriteRef
</pre>