Re: [R] Problem with fractional seconds

2009-05-26 Thread Gabor Grothendieck
seem to convert the POSIX value to Chron > times(), and Chron won't take fractional seconds.  Are there other ways to > deal with just time and not date? > > Thanks, > > Tim > > Tim Clark > Department of Zoology > University of Hawaii > > > ---

Re: [R] Problem with fractional seconds

2009-05-26 Thread Seeliger . Curt
Use format, format(myt, "%H:%M:%S%OS") -- Curt Seeliger, Data Ranger Raytheon Information Services - Contractor to ORD seeliger.c...@epa.gov 541/754-4638 > Thanks, that worked. However, is there is way to just get the time > and not have the date added? I assume the date is added since POSIX

Re: [R] Problem with fractional seconds

2009-05-26 Thread Seeliger . Curt
Thanks for beating me to that, Gabor. The %OS format spec isn't in the strptime() docs. How else might we have found this for ourselves? cur r-help-boun...@r-project.org wrote on 05/26/2009 02:59:20 PM: > > as.POSIXct(c("06:00:00.100","06:00:01.231"), format = "%H:%M:%S%OS") > [1] "2009-05-26

Re: [R] Problem with fractional seconds

2009-05-26 Thread Gabor Grothendieck
Its in the second paragraph after the list of % codes. On Tue, May 26, 2009 at 6:11 PM, wrote: > > Thanks for beating me to that, Gabor.  The %OS format spec isn't in the > strptime() docs.  How else might we have found this for ourselves? > > cur > > r-help-boun...@r-project.org wrote on 05/26/

Re: [R] Problem with fractional seconds

2009-05-26 Thread Tim Clark
here other ways to deal with just time and not date? Thanks, Tim Tim Clark Department of Zoology University of Hawaii --- On Tue, 5/26/09, Gabor Grothendieck wrote: > From: Gabor Grothendieck > Subject: Re: [R] Problem with fractional seconds > To: "Tim Clark" >

Re: [R] Problem with fractional seconds

2009-05-26 Thread Gabor Grothendieck
Try this: > as.POSIXct(c("06:00:00.100","06:00:01.231"), format = "%H:%M:%S%OS") [1] "2009-05-26 06:00:00.100 EDT" "2009-05-26 06:00:00.231 EDT" On Tue, May 26, 2009 at 5:52 PM, Tim Clark wrote: > > Dear List, > > I am having problems converting a file with fractional seconds to class > POSIXc

[R] Problem with fractional seconds

2009-05-26 Thread Tim Clark
Dear List, I am having problems converting a file with fractional seconds to class POSIXct. I have set my options to include digits.secs and my format to just time, but my output is the current date with my time lacking the fractions of a second. For example: options(digits.secs=3) t<-c("