The assets Library#
Overview#
This library is for modeling portfolios of financial instruments. Currently, the library includes one model:
BasicBonds
models a portfolio of fixed rate bonds,
generates cashflows and calculates the market value of the portfolio.
BasicBonds
uses QuantLib, a third-party
open-source library for financial instrument valuation.
Todo
This library is in its early alpha release stage, and more contents will be added in near future.
Prerequisites#
To use this library you need Quantlib-Python, a Python wrapper for QuantLib. To install Quantlib-Python from PyPI, run the following command:
pip install QuantLib
How to Use the Library#
As explained in the Copying a Library section, Create you own copy of the assets library. For example, to copy as a folder named assets under the path C:\path\to\your\, type below in an IPython console:
>>> import lifelib
>>> lifelib.create("assets", r"C:\path\to\your\assets")
Jupyter Notebooks#
Library Contents#
File or Folder |
Description |
---|---|
BasicBonds |
The |
generate_bond_data.ipynb |
Jupyter notebook Generating sample bond data |