Commit c03626ff authored by jichao's avatar jichao

但任务回测完成

parent 16c1760c
......@@ -35,7 +35,7 @@ class CurveDrift(BaseRebalanceSignal):
normal_weight = round(sum([x[1] for x in normal_portfolio.items() if x[0] in datum_ids]), 2)
hold_portfolio = self._hold.get_portfolios_weight(day, risk)
hold_weight = round(sum([x[1] for x in hold_portfolio.items() if x[0] in datum_ids]), 2)
return normal_weight - hold_weight >= self._solver.get_drift(day, risk)
return normal_weight - hold_weight >= self._solver.get_drift(day, risk) # TODO 左边应该加绝对值
@property
def diff_threshold(self):
......
......@@ -48,7 +48,7 @@ class HighBuySignal(BaseRebalanceSignal):
class LowBuySignal(HighBuySignal):
@property
def include_last_type(self):
def include_last_type(self): # TODO 回头看看要不要假如drift买入
return [
SignalType.CRISIS_ONE,
SignalType.CRISIS_TWO,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment