Closed ankurdave closed 2 years ago
This PR factors out a function called get_cashflows() and adds a simple test that already passes. This will allow a future PR to address https://github.com/hoostus/portfolio-returns/issues/3.
get_cashflows()
For ease of debugging and extensibility, get_cashflows() returns a list of Cashflow objects rather than (date, amount) tuples. This requires a small change at the callsite in irr.py.
Cashflow
(date, amount)
irr.py
Thanks!
This PR factors out a function called
get_cashflows()
and adds a simple test that already passes. This will allow a future PR to address https://github.com/hoostus/portfolio-returns/issues/3.For ease of debugging and extensibility,
get_cashflows()
returns a list ofCashflow
objects rather than(date, amount)
tuples. This requires a small change at the callsite inirr.py
.