mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
Added last value to histogram
This commit is contained in:
parent
c640a6ba21
commit
7b94198158
2 changed files with 4 additions and 0 deletions
|
@ -33,6 +33,8 @@ struct hist {
|
|||
double highest;
|
||||
/** The lowest value observed (may be lower than #low). */
|
||||
double lowest;
|
||||
/** The last value which has been put into the buckets */
|
||||
double last;
|
||||
|
||||
/** The number of buckets in #data. */
|
||||
int length;
|
||||
|
|
|
@ -38,6 +38,8 @@ void hist_destroy(struct hist *h)
|
|||
void hist_put(struct hist *h, double value)
|
||||
{
|
||||
int idx = INDEX(h, value);
|
||||
|
||||
h->last = value;
|
||||
|
||||
/* Update min/max */
|
||||
if (value > h->highest)
|
||||
|
|
Loading…
Add table
Reference in a new issue