Investment portfolio and stocks analyzing tools for Python with free historical data
Replace deprecated .append with .concat for new versions of panda package.
Add poetry as a dependency manager.
Sortino ratio and Diversification ratios:
get_sortiono_ratio()
method is available in AssetList and Portfoliodiversification_ratio
property is added to Portfolioget_most_diversified_portfolio()
method is added to EfficientFrontiermdp_points
property is added to EfficientFrontiermdp_points is a DataFrame with the Most diversified portfolios points.
More examples in Jupyter Notebooks:
New method in AssetList:
.tracking_difference_annual
to calculate tracking difference for each calendar year. See details in Documentation.Fixed:
Full Changelog: https://github.com/mbk-dev/okama/compare/v1.1.0...v1.1.1
Sharpe Ratio, Tangency portfolio and Capital Market Line (CML):
.get_sharpe_ratio()
method is available in Portfolio and AssetList.get_tangency_portfolio()
method in EfficientFrontier to optimize allocation with Sharpe Ratio as objective function.plot_cml()
method in EfficientFrontier to plot the Capital Market Line (CML) and Maximum Sharpe Ratio (MSR) point with the Efficient FrontierRefactoring:
.plot_assets()
method is at ListMaker abstract class and is available from: AssetList, Portfolio, EfficientFrontier and EfficientFrontierReb.plot_pair_ef()
method is at EfficientFrontier.plot_transition_map()
is at EfficientFrontierPlots
class discontinuedDatabase Search improvements:
ok.search()
accepts namespace as an argumentok.search()
and ok.symbols_in_namespace()
return DataFrame (default) or json. It can be changed with response_format
argument ('frame' or 'json')Bugs fixed:
.inflation_ts
by 'first_date' and 'last_date' in Portfolio and AssetListAssetList.get_dividend_mean_grow()
Documentation added for all methods and attributes in Assets, AssetList and Portfolio.
Several important updates in Portfolio and AssetList classes:
.close
and .adj_close
properties (close time series).dividend_yield
for Portfolio is a weighted sum of the assets dividend yields (adjusted to the base currency).dividends
method (dividends history time series)Several improvements to Portoflio and AssetList classes:
get_return_ts
has rebalancing_period parameterget_rebalanced_portfolio_return_ts
method in Portfolio is depreciatedget_rolling_cagr
and get_rolling_cumulative_return
could use real=True
option to calculate real return valuesget_cagr
and cumulative_return
have real
optionProject RoadMap and Contributing guidelines are added to GitHub repository.
Several bugs are fixed. New methods in Portfolio class: