Holidays and nontrading days
H = holidays
H = holidays(StartDate, EndDate)
H = holidays(AltHolidays)
Start date. Enter as a serial date number or date string.
End date. Enter as a serial date number or date string.
Alternate list of holidays and nontrading days stored as serial date numbers.
Returns a vector of serial date numbers corresponding to all holidays and nontrading days.
holidays is based on a modern 5-day workweek. This function contains all holidays and special nontrading days for the New York Stock Exchange from January 1, 1885 to December 31, 2050. Since the New York Stock Exchange was open on Saturdays before September 29, 1952, exact closures from 1885 to 2050 should include Saturday trading days. To capture these dates, use the function nyseclosures. The results from holidays and nyseclosures are identical if the WorkWeekFormat in nyseclosures is 'Modern'.
Create a vector of serial date numbers corresponding to all holidays and nontrading dates between a specified StartDate and EndDate:
H = holidays('jan 1 2001', 'jun 23 2001')
H = 730852 730866 730901 730954 730999
The serial date numbers for these values are:
01-Jan-2001 (New Year's Day) 15-Jan-2001 (Martin Luther King Day) 19-Feb-2001 (President's Day) 13-Apr-2001 (Good Friday) 28-May-2001 (Memorial Day)