Learn R Programming

RSurvey (version 0.7-9)

FormatDateTime: Build Date-Time String Formats

Description

A GUI for converting between character representations and objects of class POSIXt or Date.

Usage

FormatDateTime(sample = as.POSIXct("1991-08-25 20:57:08"), fmt = "",
               parent = NULL)

Arguments

sample
POSIXt or Date; a time object.
fmt
character; the format conversion specification string for time values.
parent
tkwin; the GUI parent window.

Value

  • Returns a character string representing the formatted date-time value.

See Also

strptime, format

Examples

Run this code
new.fmt <- FormatDateTime(fmt = "%A %B %d %I:%M %p")
FormatDateTime(Sys.Date())

Run the code above in your browser using DataLab