Merge pull request #1535 from quantopian/small-updates-for-estimates

MAINT: small updates to fix deprecation warnings
This commit is contained in:
Maya Tydykov
2016-10-12 14:41:51 -04:00
committed by GitHub
2 changed files with 6 additions and 2 deletions
+5 -1
View File
@@ -1175,7 +1175,11 @@ def get_materialized_checkpoints(checkpoints, colnames, lower_dt, odo_kwargs):
"""
if checkpoints is not None:
ts = checkpoints[TS_FIELD_NAME]
checkpoints_ts = odo(ts[ts <= lower_dt].max(), pd.Timestamp)
checkpoints_ts = odo(
ts[ts <= lower_dt].max(),
pd.Timestamp,
**odo_kwargs
)
if pd.isnull(checkpoints_ts):
materialized_checkpoints = pd.DataFrame(columns=colnames)
lower = None
@@ -532,7 +532,7 @@ class EarningsEstimatesLoader(PipelineLoader):
level=0,
inplace=True,
)
stacked_last_per_qtr = stacked_last_per_qtr.sort(
stacked_last_per_qtr = stacked_last_per_qtr.sort_values(
EVENT_DATE_FIELD_NAME,
)
stacked_last_per_qtr[EVENT_DATE_FIELD_NAME] = pd.to_datetime(