Converts a Julian date to a SAS date value
Category: Date and Time
DATEJUL ( julian-date )
julian-date
specifies a SAS numeric expression that represents a Julian date. A Julian date in SAS is a date in the form yyddd or yyyyddd , where yy or yyyy is a two-digit or four-digit integer that represents the year and ddd is the number of the day of the year. The value of ddd must be between 1 and 365 (or 366 for a leap year).
The following SAS statements produce these results:
SAS Statements | Results |
---|---|
Xstart=datejul(94365); | |
put Xstart / Xstart date9.; | 12783 |
31DEC1994 | |
Xend=datejul(2001001); | |
put Xend / Xend date9.; | 14976 |
01JAN2001 |
Function:
'JULDATE Function' on page 614