A feature release built around one idea: a financial plan is a sequence of
portfolios, not a single one. FinPlan chains stages so that the terminal
balance of each stage becomes the starting balance of the next — per Monte
Carlo scenario, not per percentile — which is what lets a retirement stage be
funded by whatever the accumulation stage actually produced. Cash-flow
strategies keep their time base across stage boundaries: indexation, extra
cash-flow compounding, Vanguard dynamic spending and the drawdown-triggered
withdrawal cut all count months from the start of the plan rather than
restarting at every stage. See
examples/04 investment portfolios with DCF.ipynb
for the single-portfolio cash-flow workflow this release generalizes.
Added
FinPlanandFinPlanStage: a financial plan modelled as a sequence of
portfolio stages. The terminal balance of each stage becomes the starting
balance of the next, per Monte Carlo scenario, so a retirement is funded by
whatever the accumulation stage produced. Plan-level methods:
FinPlan.monte_carlo_wealth,FinPlan.monte_carlo_cash_flow,
FinPlan.monte_carlo_survival_period,FinPlan.monte_carlo_irr,
FinPlan.probability_of_success,FinPlan.balance_percentiles,
FinPlan.plot_forecast_monte_carlo, and the calendar-history backtest
FinPlan.wealth_index/FinPlan.cash_flow_ts.okama.portfolios.mc.generate_returns_tsand
okama.portfolios.mc.resolve_distribution_parameters: pure functions for
drawing Monte Carlo returns, extracted fromMonteCarlo.
Changed
dcf_calculations._simulate_paths_mcacceptsinitial_balance,
month_offsetandtask. Defaults reproduce the previous behaviour, so
Portfolio.dcfis unaffected.