Dear all,

I have a time series of data that I would like to represent in a plot. But
I am facing some problems to do it because the time is represented in
"hours", it can start in one day and end in another day, and it is not
regularly spaced.

My problem is that when I plot my data, my X-axis always starts from the
lower values of my time data. For example, I would like to plot data that
starts at 20:00:00 and ends at 01:00:00, but R considers that 01:00:00 is
lower than 21:00:00 and my plot is kind of "crossed over time".

Please try this example to see it graphically:

testtime<-c("20:00:00","22:10:00","22:20:00","23:15:00","23:43:00","00:00:00","00:51:00","01:00:00")
var<-runif(length(testtime),0,1)
plot(strptime(testtime,format="%H:%M:%S"),var,type="b",xlab="Time",ylab="Var")

In this case, I would like to have a plot that starts at 20:00:00 and ends
at 01:00:00.

Does anybody know how to make R understand that 00:00:00 comes after
20:00:00 in this case? Or at least does anybody know a tip to make a plot
with this kind of X-axis?

Thanks for your time and thanks in advance for any help.

Best regards,

Charles
-- 
Um axé! :)

--
Charles Novaes de Santana, PhD
http://www.imedea.uib-csic.es/~charles

	[[alternative HTML version deleted]]

