wealth_index
- property Portfolio.wealth_index
Calculate wealth index time series for the portfolio and accumulated inflation.
Wealth index (Cumulative Wealth Index) is a time series that presents the value of portfolio over historical time period. Accumulated inflation time series is added if inflation=True in the Portfolio.
Wealth index is obtained from the accumulated return multiplied by the initial investments. That is: 1000 * (Acc_Return + 1) Initial investments are taken as 1000 units of the Portfolio base currency.
- Returns:
- DataFrame
Time series of wealth index values for portfolio and accumulated inflation.
Examples
>>> import matplotlib.pyplot as plt
>>> x = ok.Portfolio(["SPY.US", "BND.US"]) >>> x.wealth_index.plot() >>> plt.show()