Skip to content

Commit

Permalink
Update famafrench.py
Browse files Browse the repository at this point in the history
  • Loading branch information
christianjauregui committed Apr 27, 2020
1 parent d18bd8b commit 9db998c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion famafrench/famafrench.py
Original file line number Diff line number Diff line change
Expand Up @@ -4535,7 +4535,7 @@ def capitalize_nth(s, n):
if kfFreq in ['D', 'W']:
if kfFreq == 'W':
# See most recent NOTE.
dfkf.index = np.where(dfkf.index.weekday_name.isin(['Saturday', 'Sunday']), dfkf.index - BDay(1), dfkf.index)
dfkf.index = np.where(dfkf.index.day_name().isin(['Saturday', 'Sunday']), dfkf.index - BDay(1), dfkf.index)
dfkf.index = pd.to_datetime(dfkf.index).date
else:
dfkf.index = dfkf.index.to_timestamp(kfFreq).date
Expand Down

0 comments on commit 9db998c

Please sign in to comment.