Repository navigation
v4.0.0
A major release that makes financial-plan inputs explicit and lets cash-flow
searches reuse one set of simulated returns. TimeSeriesStrategy now treats
forecast dictionary amounts as nominal payments by default; pass
time_series_discounted_values=False to retain the previous compounding.
FinPlan validates stage calendars, and Asset gains scalar CAGR and checked
monthly-price accessors.
Added
Asset.get_cagr(period=None, real=False)returns the annualized return of a
single asset over its full history or a trailing number of years, optionally
adjusted for inflation in the asset's currency.Asset.get_close_monthly(month)looks up a monthly closing price and names
the requested month and available range when the month is unavailable.FinPlan.stage_month_indicesexposes each forecast stage's calendar.
FinPlan.draw_return_paths()andFinPlan.run_monte_carlo(return_paths=...)
let several cash-flow variants reuse the same simulated returns.FinPlanaccepts an optionalt0to check the intended forecast start against
every stage portfolio'slast_date.
Changed
- Breaking.
TimeSeriesStrategy.time_series_discounted_valuesdefaults to
True: Monte Carlo forecasts use supplied amounts verbatim as nominal cash
flows. PassFalseexplicitly to retain the previous default, which compounds
amounts from today's money usingdiscount_rate. In a historical backtest,
Truecompounds the supplied amounts andFalseuses them verbatim; choose
the flag explicitly when the same ledger is used in both modes. IndexationStrategy.amountaccepts withdrawals larger than the strategy's
owninitial_investment. AFinPlanuses its plan-level opening balance;
the simulation determines whether subsequent withdrawals can be funded.
Fixed
FinPlan.plot_forecast_monte_carlohas a self-contained documentation example
that constructs the portfolio and plan before plotting.FinPlanreports inconsistent stage portfolio end dates and rejects
TimeSeriesStrategy.time_series_dickeys outside their owning stage's range
when running the selected forecast or historical backtest.FinPlan.discount_ratelogs the effective rate when selecting its automatic
inflation or default fallback.AssetListwarns when inflation availability shortens an explicitly
requestedlast_date.AssetList.get_cagrdocuments the common measurement
window and inflation column; useinflation=Falsefor the full nominal window.FinPlan.monte_carlo_wealthexplains the cumulative meaning of positive
balances after ruin masking, andFinPlan.monte_carlo_cash_flowdocuments
remove_if_wealth_index_negative=Falsefor checking the raw modeled flows.