Thursday 10 February 2011

GnuPlot "all points y value undefined" with "set timefmt %s"

Try as I might, I couldn't get MacPorts GnuPlot ("4.2 patchlevel 5") to restrict the range of some time data I was plotting (as usual, I'm not the only one):

gnuplot> set xdata time
gnuplot> set timefmt "%s"
gnuplot> set xrange ["1297212300":"1297256400"]
gnuplot> plot "battery_graph_Feb09-002305_to_Feb09-130805.csv" \
using 2:3 with lines
^
all points y value undefined!

gnuplot> show xrange

set xdata time
set xrange [ "" : "" ] noreverse nowriteback

gnuplot> set xrange ["1297212300":"1297256400"]
gnuplot> show xrange

set xdata time
set xrange [ "" : "" ] noreverse nowriteback



Solution: roll the latest version from source (Version 4.4 patchlevel 2; I couldn't work out what version fixed it from the ChangeLog and don't care to binary-chop it). Downside: can't quite work out how to enable AquaTerm support.

No comments:

Post a Comment