Update holiday.py to reflect that MLK Jr. Day was first observed in 1986. 
State: closed

closes #9760

Fixing MLK day not observed before 1986, per https://github.com/pydata/pandas/issues/10278#issuecomment-109002244


Labels:
name: Frequency
description: DateOffsets

Comments:
Hi, 
I also noticed what appear to be two additional inconsistencies. 
- Memorial day is the last Monday in May. Code as before would not work if May 31st were a Monday. 
- New Years Day is not offset to the nearest workday in the US calendar as far as I can tell. 

Memorial day is already fixed in #9763 but it needs a test before it can be pushed.  Maybe it's best to incorporate the test there into this PR.  Also, all your other changes need tests.

Also, New Year's Day is offset to the nearest workday for US Holidays.  https://www.opm.gov/policy-data-oversight/snow-dismissal-procedures/federal-holidays/.  Every other calendar used for holiday work uses a similar convention and so I think it makes sense to leave the rule as it is.  These rules are mostly meant to be examples and cover the standard use cases so it makes sense to leave New Years going to nearest_workday.

OK, thanks. That makes a lot of sense. And you're right re: federal
holidays. I misread the spec. And they are a good example.

If Memorial Day is fixed elsewhere, then it seems like only MLK is the only
change that should actually be fixed. Sorry for the churn.

Thanks,
Chris

On Fri, Jun 5, 2015 at 8:58 AM, rockg notifications@github.com wrote:

> Also, New Year's Day is offset to the nearest workday for US Holidays.
> https://www.opm.gov/policy-data-oversight/snow-dismissal-procedures/federal-holidays/.
> Every other calendar used for holiday work uses a similar convention and so
> I think it makes sense to leave the rule as it is. These rules are mostly
> meant to be examples and cover the standard use cases so it makes sense to
> leave New Years going to nearest_workday.
> 
> —
> Reply to this email directly or view it on GitHub
> https://github.com/pydata/pandas/pull/10282#issuecomment-109284674.

## 

Chris Clearfield

@clearf can you add some tests?

@jreback sorry for the delay (camping). Happy to add some tests.

Some pointers to the test/build process would be great.

Thanks,
Chris

On Fri, Jun 26, 2015 at 4:33 PM, jreback notifications@github.com wrote:

> @clearf https://github.com/clearf can you add some tests?
> 
> —
> Reply to this email directly or view it on GitHub
> https://github.com/pydata/pandas/pull/10282#issuecomment-115917681.

## 

Chris Clearfield

http://pandas.pydata.org/pandas-docs/stable/contributing.html

Great, thanks.

On Fri, Jul 3, 2015 at 6:09 PM, jreback notifications@github.com wrote:

> http://pandas.pydata.org/pandas-docs/stable/contributing.html
> 
> —
> Reply to this email directly or view it on GitHub
> https://github.com/pydata/pandas/pull/10282#issuecomment-118447458.

## 

Chris Clearfield

@jreback Per above, added tests for MLK day. Also added tests for Memorial day fix, though my implementation is slightly different than that referenced in https://github.com/pydata/pandas/pull/9763

Sorry it took so long. 

looks good. couple of minor comments, then pls squash. ping when green.

@jreback, OK, comments added and imports moved. All checks passed. 

And my apologies: I squashed my most recent commits, but could not figure out how to squash my commits from early June that predated the merge. Let me know if you know how to do this and I can fix. 

contributing docs here: http://pandas.pydata.org/pandas-docs/stable/contributing.html

pls rebase/squash

Ok, thanks.

On Mon, Aug 10, 2015 at 04:04 Jeff Reback notifications@github.com wrote:

> contributing docs here:
> http://pandas.pydata.org/pandas-docs/stable/contributing.html
> 
> pls rebase/squash
> 
> —
> Reply to this email directly or view it on GitHub
> https://github.com/pydata/pandas/pull/10282#issuecomment-129408546.

[edit] @jreback Jeff, I think I rebased all my commits correctly and pushed. But I still see 226 files changed, when obviously I only changed a few. I'm still not sure if I'm doing this correctly. I think some of these are from my upstream fetch? 

Sorry, this is my first time doing this. I'm happy to start from scratch with a new PR. 

you need to `git rebase -i origin/master`

@jreback And... I think we're there. Thanks for the guidance/patience. 

merged via https://github.com/pydata/pandas/commit/8ccdf4821f2dcac2b2c0f210d07679b5178f0211

thanks!

Small victories. :)
On Tue, Aug 18, 2015 at 04:09 Jeff Reback notifications@github.com wrote:

> Closed #10282 https://github.com/pydata/pandas/pull/10282.
> 
> —
> Reply to this email directly or view it on GitHub
> https://github.com/pydata/pandas/pull/10282#event-385240783.