time_series_stats.cpp
Example for RDM::TIME_SERIES template classes. This example needs a compiled schema, time_series_stats.sdl.
#include "time_series_stats_structs.h"
#include "rdm_time_series_stats.h"
#include "rdm_time_series_split.h"
#include "rdm_time_series_dead_end.h"
#include "rdm_db_insert_row.h"
#include <math.h>
{
using namespace RDM_CPP::TIME_SERIES_STATS;
using namespace RDM::TIME_SERIES;
using namespace RDM::DB;
stats <32, MEASUREMENT_STATS1,
stats <32, MEASUREMENT_STATS1,
/* Place holder for something to come: */
dead_end>>ts_chain;
{
const double tau = 6.283185307179586;
const double signal = sin (tau * time_stamp / 50);
RDM_CPP::TIME_SERIES_STATS::MEASUREMENT measurement = {time_stamp, signal};
rc = ts_chain.put_value (&measurement);
}
return rc;
}
Time series for dead end template class.
Time series for split template classes.
RDM_RETCODE init(RDM_DB)
Initialize this object.
Definition: rdm_time_series_dead_end.h:153
Time series for stats template class.
Template Class for doing a 3-way split.
Definition: rdm_time_series_split.h:648
Time series for insert_row template class.