Re: [R] Weird POSIXct behaviour

2012-12-10 Thread Worik R
I thought I had solved this problem. But I am still having trouble converting times. I am looking for a way to print out the string versions of times in different time zones. Same time, different zones. I have times stored as seconds since epoch and as text strings in local time. For instance

Re: [R] Weird POSIXct behaviour

2012-03-29 Thread Worik R
On Fri, Mar 30, 2012 at 2:53 PM, Joshua Ulrich wrote: > On Thu, Mar 29, 2012 at 3:56 PM, Worik R wrote: > > > I removed the (not so minimal) reproducible example because you can > get the same behavior via: > > (s <- Sys.time()) > [1] "2012-03-29 20:43:35 CDT" > > as.POSIXct(as.numeric(s),origin

Re: [R] Weird POSIXct behaviour

2012-03-29 Thread Joshua Ulrich
On Thu, Mar 29, 2012 at 3:56 PM, Worik R wrote: > I have a reproducible example of my problem below > > On Mon, Mar 26, 2012 at 9:22 AM, Joshua Ulrich > wrote: >> >> > Given two identical string representations of POSIXct objects, can the >> > two >> > objects represent different times? >> > >> Y

Re: [R] Weird POSIXct behaviour

2012-03-29 Thread Worik R
I have a reproducible example of my problem below On Mon, Mar 26, 2012 at 9:22 AM, Joshua Ulrich wrote: > > Given two identical string representations of POSIXct objects, can the > two > > objects represent different times? > > > Yes. Here's an example (from my Ubuntu machine) of one way: > > >

Re: [R] Weird POSIXct behaviour

2012-03-25 Thread Joshua Ulrich
On Sun, Mar 25, 2012 at 3:01 PM, Worik R wrote: > My bad.  I should be clearer about the source of my confusion. > > Given two identical string representations of POSIXct objects, can the two > objects represent different times? > Yes. Here's an example (from my Ubuntu machine) of one way: > (t1

Re: [R] Weird POSIXct behaviour

2012-03-25 Thread Worik R
My bad. I should be clearer about the source of my confusion. Given two identical string representations of POSIXct objects, can the two objects represent different times? > > Where has it gone? > > > It's hard to say, especially since you give no indication how you > assigned the value to Time

Re: [R] Weird POSIXct behaviour

2012-03-25 Thread Joshua Ulrich
On Sun, Mar 25, 2012 at 3:15 AM, Worik R wrote: > Friends > > I have an xts that I wish to access. > > Browse[2]> DATA.ba[[p]]["2012-03-20 00:59:57","bid"] >                       bid > 2012-03-20 00:59:57 1.4993 > > So far so good. > > Now putting the index into a variable: > > Browse[2]> Time >

Re: [R] Weird POSIXct behaviour

2012-03-25 Thread peter dalgaard
I see "NZDT" going in and out of your time values. Could that have something to do with it? On Mar 25, 2012, at 10:15 , Worik R wrote: > Friends > > I have an xts that I wish to access. > > Browse[2]> DATA.ba[[p]]["2012-03-20 00:59:57","bid"] > bid > 2012-03-20 00:59:57 1

[R] Weird POSIXct behaviour

2012-03-25 Thread Worik R
Friends I have an xts that I wish to access. Browse[2]> DATA.ba[[p]]["2012-03-20 00:59:57","bid"] bid 2012-03-20 00:59:57 1.4993 So far so good. Now putting the index into a variable: Browse[2]> Time [1] "2012-03-20 00:59:57 NZDT" Browse[2]> DATA.ba[[p]][Time, "bid"]