Remove indexing warning in edge

This commit is contained in:
Matthias 2020-03-14 10:42:01 +01:00
parent 5bfbf92e69
commit c56cbc21b1

View File

@ -317,7 +317,7 @@ class Edge:
}
# Group by (pair and stoploss) by applying above aggregator
df = results.groupby(['pair', 'stoploss'])['profit_abs', 'trade_duration'].agg(
df = results.groupby(['pair', 'stoploss'])[['profit_abs', 'trade_duration']].agg(
groupby_aggregator).reset_index(col_level=1)
# Dropping level 0 as we don't need it