Hello

Thanks for writing and maintaining the Rmetrics package!

I am working with the Rmetrics holiday calendar and noticed a slight 
error in NYSE holidays before 1971.
I have to admit my point to be picky (who cares about trading holiday's 
before 1971), but you might still want to correct the source code.

According to NYSE's holiday calendar,  Washington's birthay was observed 
at NYSE as follows:
http://www.nyse.com/about/newsevents/1176373643795.html:[..] * 
Washington's Birthday was first declared a federal holiday by an 1879 
act of Congress. The Monday Holiday Law, enacted in 1968, shifted the 
date of the commemoration of Washington's Birthday from February 22 to 
the third Monday in February [..]
http://www.nyse.com/pdfs/closings.pdf [..] Washington's Birthday (Feb. 
22) Closed every year. Observed on Mondays since 1971.[..]

The function holidayNYSE implements WashingtonsBirthday/PresidentsDay by 
calling USWashingtonsBirthday() before 1971 and USPresidentsDay() from 
1971 on.
Unfortunately, USWashingtonsBirthday() is defined in the same way as 
USPresidentsDay() (third Monday in February) instead of returning 
February 22nd.
    USWashingtonsBirthday <- function (year = currentYear)
    {
        # instead of the third Monday in February (ans = 
.nth.of.nday(year, 2, 1, 3))
        # use February 22nd as trading holiday on NYSE before 1971
        ans = year * 10000 + 222
        timeDate(as.character(ans))
    }

Please also note a slight error in the holidayNYSE function: the 
following conditions are both TRUE for the year 1970. The second 
condition should read (y > 1970) instead of (y >= 1970).
    holidayNSYE <- function( year=currentYear )
    [..]
        if (y <= 1970)
            holidays = c(holidays, as.character(USWashingtonsBirthday(y)))
        if (y >= 1970)
            holidays = c(holidays, as.character(USPresidentsDay(y)))
    [..]


Best Regards,
Lukas Elmiger





	[[alternative HTML version deleted]]

