I'm using jsrrdgraph in some projects to visualize measurements - compliments, a great improvement over statically (with rrdgraph) created graphs which makes analyzing values much more comfortable!
Today for the first time I tried to use TREND and TRENDNAN to get the moving average of a time series of measurements with a step of 1s; the command line version works as expected:
displays the movement-line as expected, but the moving average lines are always zero. I could "work around" the problem calculating the MA for the last 10 values by hand:
But obviously that would be a hard work for the last 180 values. :-)
I'm using jsrrdgraph in some projects to visualize measurements - compliments, a great improvement over statically (with rrdgraph) created graphs which makes analyzing values much more comfortable!
Today for the first time I tried to use TREND and TRENDNAN to get the moving average of a time series of measurements with a step of 1s; the command line version works as expected:
rrdtool graph movement.png -a PNG -s end-10min -v 'Bewegung' -t 'Bewegung' -E \ 'DEF:movement=/var/lib/rrd/measurements.rrd:movement:AVERAGE' \ 'CDEF:movementMA30s=movement,30,TRENDNAN' \ 'CDEF:movementMA3m=movement,180,TRENDNAN' \ 'LINE2:movement#ff0000: Bewegung []' \ 'LINE2:movementMA30s#8000FF: Bewegung MA 300s []' \ 'LINE2:movementMA3m#00FF00: Bewegung MA 30min []'
The jsrrdgraph version:
displays the movement-line as expected, but the moving average lines are always zero. I could "work around" the problem calculating the MA for the last 10 values by hand:
But obviously that would be a hard work for the last 180 values. :-)
Examples for all three methods:
I'm using the last version got with git clone.
Any ideas? Thank you!
Markus