Skip to content

Commit

Permalink
state.volume
Browse files Browse the repository at this point in the history
  • Loading branch information
tschm committed Nov 20, 2023
1 parent 0529808 commit 92a5f28
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 3 additions & 0 deletions cvx/simulator/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,6 +151,9 @@ def update(
# builder is frozen, so we can't construct a new state
return self

def __getattr__(self, item):
return self.input_data[item]


def builder(
prices: pd.DataFrame,
Expand Down
2 changes: 0 additions & 2 deletions tests/test_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,6 @@ def test_returns(prices):
def test_cov(prices):
b = _builder(prices=prices, initial_cash=50000)
for time, mat in b.cov(min_periods=50, com=50):
# print(time)
# print(mat)
assert np.all(np.isfinite(mat))


Expand Down

0 comments on commit 92a5f28

Please sign in to comment.