As a gnuplot user for many years, I'm going to despair with R trying to align the grid for time-based values to the x-axis labels, i.e. to some "reasonable" multiples of human time (minutes, hours, days, etc.). In Gnuplot it's more or less automatic...
For example I have these time values (I still couldn't find out how to use dump()
properly, so a simplified example without measurement data):
> range(perf$time)
[1] "2016-11-22 02:26:02 CET" "2016-11-22 04:02:12 CET"
> length(perf$time)
[1] 49
> plot(perf$time, 1:length(perf$time))
> grid()
>
The plot window looks like this:
So you see that "3:00" matches a grid line, but no other value. I tried to make the number of lines matching, but couldn't get the alignment right. Isn't there a simple solution?
None of the solutions for "Placing the grid along date tickmarks" uses grid()
, so is grid()
rather useless?