Reputation: 551
I tried to find whether it has one, but there seems to be none in help.
help(date)
Upvotes: 0
Views: 206
Reputation: 226597
No, it doesn't have any arguments. date()
:
Returns a character string of the current system date and time.
Are you looking for as.Date()
?
apropos("(^|\\.)date")
will show you all the currently available functions (i.e., in base R) that either start with "date"` or have a dot followed by "date" (case-insensitive):
[1] "-.Date" ".Date" "[.Date"
[4] "[[.Date" "[<-.Date" "+.Date"
[7] "as.character.Date" "as.data.frame.Date" "as.Date"
[10] "as.Date.character" "as.Date.default" "as.Date.factor"
[13] "as.Date.numeric" "as.Date.POSIXct" "as.Date.POSIXlt"
[16] "as.list.Date" "as.POSIXct.Date" "as.POSIXlt.Date"
[19] "axis.Date" "c.Date" "cut.Date"
[22] "date" "diff.Date" "format.Date"
[25] "is.numeric.Date" "julian.Date" "length<-.Date"
[28] "Math.Date" "mean.Date" "months.Date"
[31] "Ops.Date" "print.Date" "quarters.Date"
[34] "rep.Date" "round.Date" "seq.Date"
[37] "split.Date" "summary.Date" "Summary.Date"
[40] "Sys.Date" "trunc.Date" "weekdays.Date"
[43] "xtfrm.Date"
Upvotes: 5