Question

I'm generating a graph with gnuplot of activity over the last twenty four hours, but the time axis looks really bad because it's trying to fit the long number for every five minutes in the last day.

Is there any way for gnuplot to treat the x-axis as an epoch time, and mark every hour or so?

Was it helpful?

Solution

Is this what you want?

set xdata time
set timefmt "%s"
# set xtics 3600
set format x "%H:%M:%S" # or whatever
plot ...

OTHER TIPS

i followed this from the gnuplot howto :

03/21/95 10:00 6.02e23

This file can be plotted by

   set xdata time
   set timefmt "%m/%d/%y"
   set xrange ["03/21/95":"03/22/95"]
   set format x "%m/%d"
   set timefmt "%m/%d/%y %H:%M"
   plot "data" using 1:3
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top