Hi, Gabor
It works now, thanks. The tricky part is I imported my data from Excel
and converted the data into POSIXct format using command strptime().
So I thought they were already converted into dates and times class. I
added as.POSIct, now it works alright.
Thanks for that
Gabor Grothend
On Tue, 15 Jan 2008, Jingru Dai wrote:
> Hi, everyone
>
> I've been trying to make a scatter plot of POSIXct format data to see
> the difference between two start time.
> Like X:
> [1] "1995-05-26 19:00:00" "1995-05-27 01:00:00" "1995-05-27 07:00:00"
> [4] "1995-06-29 01:00:00" "1995-06-29 07:00:0
When I try this:
> x <- as.POSIXct(Sys.Date() + 0:9)
> plot(x, x)
> plot(x ~ x)
The first one does give me dates on both axes but the second one gives
numbers on the Y axis.
Note that you can always not print the axis with plot and then do it yourself
with axis or Axis. This works for me:
> pl
3 matches
Mail list logo