Skip to content

Commit

Permalink
more properties for compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
Cuizi7 committed Dec 4, 2018
1 parent 7f1217c commit ab47399
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions rqalpha/model/benchmark_portfolio.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,12 @@ def static_unit_net_value(self):
def total_value(self):
return self.units * self.unit_net_value

# Only for compatible

@property
def cash(self):
return 0

@property
def market_value(self):
return self.total_value
market_value = total_value
portfolio_value = total_value
starting_cash = units

0 comments on commit ab47399

Please sign in to comment.