Parametric Bootstrapping via the GARCH model
Project description
ParametricGarch
A Python library that uses parametric bootstrapping via the GARCH model to estimate volatility and Value-at-Risk (VaR) for financial assets.
Installation
You can install parametricGarch using pip:
pip install parametricGarch
Dependencies
The package dependencies are:
- arch
- numpy
- pandas
- scipy
Usage
To get started with parametricGarch, import the necessary modules and create an instance of the Garch
class:
from parametricGarch import Garch
# Create an instance of the Garch class to fit and forecast the model
model = Garch(data, vol='Garch', p=1, q=1, dist='normal', update_freq=0, disp='off', horizon=1, start=None, reindex=False)
# View the summary of the fitted model
model.summary
# View the conditional volatility of the fitted model
model.conditional_volatility
# View the standardised residuals of the fitted model
model.standardised_residuals
# View the forecasted conditional mean of the fitted model
model.forecast_mean
# View the forecasted conditional variance of the fitted model
model.forecast_variance
# View the forecasted conditional variance of the residuals of the fitted model
model.forecast_residual_variance
# Perform parametric bootstrapping
model.bootstrap()
# View the summary of the bootstrapped model
model.bootstrap_summary
# View the forecasted mean and volatility list from the bootstrapped model
model.bootstrap_samples
# Estimate volatility and VaR
risk_estimates = model.estimate_risk()
Documentation
Please refer to the documentation for detailed information on the available parameters, methods, and properties of the Garch class.
Examples
Please refer to example.ipynb
for a detailed example to help you get started quickly with parametricGarch. The examples cover various use cases and demonstrate the library's capabilities.
License
parametricGarch is licensed under the GNU General Public License v3.0 License. See the LICENSE file for more details.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file parametricGarch-0.0.6.tar.gz
.
File metadata
- Download URL: parametricGarch-0.0.6.tar.gz
- Upload date:
- Size: 17.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 13c0367fac4008cc8464b5d84bd7ebef3d02ee1ee68a49bdafedfc050101f593 |
|
MD5 | aa5c5c763e54dc539ec9eec5d92385b4 |
|
BLAKE2b-256 | 37d3825b8b334f3f71e0a566840bfe80b62368a7ea660ded8c0e3cba8c5abbdf |
File details
Details for the file parametricGarch-0.0.6-py3-none-any.whl
.
File metadata
- Download URL: parametricGarch-0.0.6-py3-none-any.whl
- Upload date:
- Size: 17.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.9.12
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 774f2fb6126bc10a17c268800f86406a3a7e5c6b6186f3410d25d948ba6fbb07 |
|
MD5 | bb7aab065d4ecf96d2e0db60b242fce0 |
|
BLAKE2b-256 | faa4e1612cb2e3bc62f8a2e66da41c70b2d04f3195358552b50cdcef0b4e00ac |