Disaggregate
Disaggregate Smart Meter data
|
#include <Histogram.h>
Public Member Functions | |
Histogram (const Array< Sample_t > &source, const size_t xaxis=MAX_WATTAGE) | |
Create a (relative) histogram from a sample array. | |
virtual const std::string | getBaseFilename () const |
virtual void | drawGraph () |
const size_t | getSizeOfSource () const |
Protected Attributes | |
size_t | sizeOfSource |
Definition at line 14 of file Histogram.h.
Histogram::Histogram | ( | const Array< Sample_t > & | source, |
const size_t | xaxis = MAX_WATTAGE |
||
) |
Create a (relative) histogram from a sample array.
xaxis | Number of elements on the xaxis of the histogram |
Definition at line 13 of file Histogram.cpp.
References Array< Histogram_t >::data, Array< Histogram_t >::deviceName, Array< T >::getDeviceName(), Array< T >::getSmoothing(), Utils::roundToNearestInt(), Array< Histogram_t >::setAllEntriesTo(), Array< Histogram_t >::setSize(), sizeOfSource, Array< Histogram_t >::smoothing, and Array< Histogram_t >::upstreamSmoothing.
void Histogram::drawGraph | ( | ) | [virtual] |
Definition at line 42 of file Histogram.cpp.
References GNUplot::PlotVars::data, Array< Histogram_t >::dumpToFile(), getBaseFilename(), GNUplot::PlotVars::inFilename, GNUplot::PlotVars::outFilename, GNUplot::plot(), GNUplot::PlotVars::plotArgs, GNUplot::PlotVars::title, GNUplot::PlotVars::xlabel, and GNUplot::PlotVars::ylabel.
Referenced by Signature::updatePowerStates().
const std::string Histogram::getBaseFilename | ( | ) | const [virtual] |
Reimplemented from Array< Histogram_t >.
Definition at line 34 of file Histogram.cpp.
References Array< Histogram_t >::deviceName, Utils::size_t_to_s(), Array< Histogram_t >::smoothing, and Array< Histogram_t >::upstreamSmoothing.
Referenced by drawGraph(), and Signature::drawHistWithStateBars().
const size_t Histogram::getSizeOfSource | ( | ) | const |
Definition at line 64 of file Histogram.cpp.
References sizeOfSource.
Referenced by Statistic< Sample_t >::Statistic().
size_t Histogram::sizeOfSource [protected] |
Definition at line 30 of file Histogram.h.
Referenced by getSizeOfSource(), and Histogram().