mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
fix histograms plots
This commit is contained in:
parent
ab8723ba8f
commit
14c03ee70c
1 changed files with 5 additions and 4 deletions
|
@ -134,11 +134,12 @@ void hist_plot(struct hist *h)
|
|||
line();
|
||||
|
||||
for (int i = 0; i < h->length; i++) {
|
||||
int bar = HIST_HEIGHT * ((double) h->data[i] / max);
|
||||
if (bar == 0)
|
||||
continue;
|
||||
double value = VAL(h, i);
|
||||
int cnt = h->data[i];
|
||||
int bar = HIST_HEIGHT * ((double) cnt / max);
|
||||
|
||||
stats("%+9g | " "%5u" " | %.*s", VAL(h, i), h->data[i], bar, buf);
|
||||
if (value > h->lowest || value < h->highest)
|
||||
stats("%+9g | " "%5u" " | %.*s", value, cnt, bar, buf);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue