0
votes

I am trying to use gnuplot from a csv file. There are quite a bit of similar posts but I haven't had any success from them. There should be 4 lines marked by the integer values and the times should make up the x axis.

data file: first column is H:M:S, rest are 0-100 values

00:26:45,34,12,3,7
00:27:14,31,10,5,9
00:27:43,27,7,2,4
00:28:18,32,11,4,6
00:28:45,36,17,6,7
00:29:35,39,16,1,3
00:30:48,24,12,5,4
00:31:33,32,9,2,8
00:32:15,27,12,3,7
00:32:45,34,15,6,4

gnuplot commands:

set datafile separator ","
set yrange [0:100]
set xrange ["00:00:00":"24:00:00"]
set xtics format '%H:%M:%S'
set timefmt '%H:%M:%S'
set xdata time
plot 'test.csv' using 1:2 with lines

So far all I get is a blank plot with 5 second increments starting at 00:00:00. Any help would be greatly appreciated.

1

1 Answers

0
votes

I was able to get the plot to show correctly by removing the xrange line. But the x-axis still doesnt display the exact times from the first column, Just every hour. Seems to just be a matter of more formatting.