Perhaps use the correct function. (Just one little letter off...)
--
Sent from my phone. Please excuse my brevity.
On September 11, 2016 10:57:39 PM PDT, Chris Evans wrote:
>I am trying to read activity data created by Garmin. It outputs dates
>like this:
>
>"Thu, 25 Aug
Not sure what the issue is with the provided code but note:
library(lubridate)
lubridate::dmy_hm("Thu, 25 Aug 2016 6:34 PM")
[1] "2016-08-25 18:34:00 UTC"
Though if you go that route: set the TZ because on the timestamp it is
ambiguous.
On Sun, Sep 11, 2016 at 10:57 PM, Chris Evans
On 12 Sep 2016, at 12:33 , Chris Evans wrote:
> OK. I'm an idiot (not for the first time and, sadly, no doubt not for the
> last). strptime() was all that was needed: just that one pesky character and
> I can't remember now why I went astray there, but thanks to all who
On 9/11/2016 10:57 PM, Chris Evans wrote:
I am trying to read activity data created by Garmin. It outputs dates like this:
"Thu, 25 Aug 2016 6:34 PM"
The problem that has stumped me is this:
strftime("Thu, 25 Aug 2016 6:34 PM",format="%a, %d %b %Y %I:%M %p")
Error in as.POSIXlt.character(x,
It should be strptime for character vectors.
strptime("Thu, 25 Aug 2016 6:34 PM",format="%a, %d %b %Y %I:%M %p”)
> On 12 Sep 2016, at 08:57, Chris Evans wrote:
>
>> strftime("Thu, 25 Aug 2016 6:34 PM",format="%a, %d %b %Y %I:%M %p")
[[alternative HTML version
> On 12 Sep 2016, at 07:57 , Chris Evans wrote:
>
>> strftime("Thu, 25 Aug 2016 6:34 PM",format="%a, %d %b %Y %I:%M %p")
strptime, not strftime...
--
Peter Dalgaard, Professor,
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg,
On Mon, 12 Sep 2016, Chris Evans writes:
> I am trying to read activity data created by Garmin. It outputs dates like
> this:
>
> "Thu, 25 Aug 2016 6:34 PM"
>
> The problem that has stumped me is this:
>
>> strftime("Thu, 25 Aug 2016 6:34 PM",format="%a, %d %b %Y %I:%M
.
As ever, deeply indebted to the R and R-help communities,
Chris
> From: "Ismail SEZEN" <sezenism...@gmail.com>
> To: "Chris Evans" <chrish...@psyctc.org>
> Cc: "r-help" <r-help@r-project.org>
> Sent: Monday, 12 September, 2016 10:36:51
&
I am trying to read activity data created by Garmin. It outputs dates like this:
"Thu, 25 Aug 2016 6:34 PM"
The problem that has stumped me is this:
> strftime("Thu, 25 Aug 2016 6:34 PM",format="%a, %d %b %Y %I:%M %p")
Error in as.POSIXlt.character(x, tz = tz) :
character string is not in a
9 matches
Mail list logo