1\name{date.mdy}
2\alias{date.mdy}
3\title{Convert from Julian Dates to Month, Day, and Year}
4\description{
5  Convert a vector of Julian dates to a list of vectors with the
6  corresponding values of month, day and year, and optionally weekday.
7}
8\usage{
9date.mdy(sdate, weekday = FALSE)
10}
11\arguments{
12  \item{sdate}{a Julian date value, as returned by \code{mdy.date()},
13    number of days since 1/1/1960.}
14  \item{weekday}{if \code{TRUE}, then the returned list also will
15    contain the day of the week (Sunday=1, Saturday=7).}
16}
17\value{
18  A list with components \code{month}, \code{day}, and \code{year}.
19}
20\examples{
21day <- 7
22temp <- date.mdy(mdy.date(month = 7, day = day, year = 1960))
23## Check for illegal dates, such as 29 Feb in a non leap year
24if (temp$day != day) {
25  cat("Some illegal dates\n")
26} else {
27  cat("All days are legal\n")
28}
29}
30\references{
31  Press, W. H., Teukolsky, S. A., Vetterling, W. T., and Flannery,
32  B. P. (1992).
33  \emph{Numerical Recipes: The Art of Scientific Computing (Second
34    Edition)}.
35  Cambridge University Press.
36}
37\keyword{chron}
38