% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/date.R
\name{date_format}
\alias{date_format}
\title{Formatting: date and date-time}
\usage{
date_format(x, ...)
}
\arguments{
\item{x}{\verb{[Date / POSIXct / POSIXlt]}

A date or date-time vector.}

\item{...}{These dots are for future extensions and must be empty.}
}
\value{
A character vector of the formatted input.
}
\description{
\code{date_format()} formats a date (Date) or date-time (POSIXct/POSIXlt) using
a \code{format} string.

There are separate help pages for formatting dates and date-times:
\itemize{
\item \link[=date-formatting]{dates (Date)}
\item \link[=posixt-formatting]{date-times (POSIXct/POSIXlt)}
}
}
\examples{
# See method specific documentation for more examples

x <- as.Date("2019-01-01")
date_format(x, format = "year: \%Y, month: \%m, day: \%d")
}
