Description Usage Arguments Value See Also Examples
Convers character to POSIXct
1 | string.to.POSIXct(x, format, tz = getOption("date.reader")$tz)
|
x |
character; vector to convert to a POSIX date |
format |
character; name of the format for the values. If this parameter is NA, then the function will try to guess the format for each value |
tz |
character; optional time zone |
POSIXct vector (or NA, if a value cannot be parsed)
as.POSIXct
strptime
for format
strings
1 2 3 4 5 6 7 8 9 10 11 12 13 | ## Not run:
dts <- c( '20140210', '19791118', '19720329' )
string.to.POSIXct( dts )
dts <- rep( '20140210', 10 )
string.to.POSIXct( dts )
dts <- c( '14-02-10', '79-11-18' ) # FAIL(?)
string.to.POSIXct( dts )
string.to.POSIXct( dts, format='ymd' )
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.