1
0
Fork 0
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:
Steffen Vogel 2015-10-08 10:49:51 +02:00
parent c640a6ba21
commit 7b94198158
2 changed files with 4 additions and 0 deletions

View file

@ -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;

View file

@ -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)