I've modified an old algo with some additional factors and new rankings. The rebalance function of the algo contains a deprecated line of code that runs an d completes with a WARN before May/31/2017, but fails any date after May/31/2017.
Here the lines:
print slopes.order(ascending=False).head(100)
ranking_table = slopes[slopes > slopes.quantile(1 - context.rank_table_percentile)].order(ascending=False)
Here are the WARN I'm getting, when the end-date is set to on before May/31/2017:
016-01-04 15:00 WARN :185: FutureWarning: order is deprecated, use sort_values(...)
2016-01-04 15:00 WARN :187: FutureWarning: order is deprecated, use sort_values(...)
Here are the errors I'm getting when the end-date is set to after May/31/2017,
AttributeError: 'DataFrame' object has no attribute 'order'
I've update the line with the following:
ranking_table = slopes[slopes > slopes.quantile(1 - context.rank_table_percentile)].sort_values(ascending=False)
This didn't work. Any help would be appreciated.
Thnx