Hi, I'm working with timeseries data. The values are every 5 seconds and each series can last up to 4-5 days.
To generate the x-axis labels, I'm doing the following: ========================= # Variable for displaying hours on the x-axis rtime <<- as.POSIXct(round(range(timedata), "hours")) # Variable for displaying days on the x-axis stime <<- as.POSIXct(round(range(timedata), "days")) # Plot the hours on the x-axis axis.POSIXct(1, at=seq(rtime[1], rtime[2], by="hour"), format="%H", cex.axis=.6, lwd=0, lwd.ticks=1, hadj=0.2, las=2, tck=-0.02) # Plot the days on the x-axis axis.POSIXct(1, at=seq(stime[1], stime[2], by="day"), format="%A", cex.axis=.7, line=1, lty=0, padj=-1.4) ========================= The data generated and the plots look fine. R issues a warning on the round() function when rtime is set, though. It looks like this: > round(range(cgmtime), "hours") [1] "2003-11-04 14:00:00 EST" "2003-11-07 11:00:00 EST" Warning message: In if (isdst == -1) { : the condition has length > 1 and only the first element will be used > Am I approaching this incorrectly? Is there another way to achieve the same result without the warning? Or is there a way I can suppress the warning? Thanks in advance, Clay ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.