Awesome but light option price calculator in Python
Project description
option-price
option-price is a Python-based powerful but simple option price calculator.
Installation
pip install option-price
Usage
from optionprice import Option
You can initialize an option through this:
some_option = Option(european=False,
kind = 1,
s0 = 100,
k=120,
t=45,
sigma=0.01,
r=0.05
dv = 0)
option-price has three approaches to calculate the price of the price of the option. They are
- B-S-M
- Monte Carlo
- Binary Tree
option-price will pick B-S-M by default. You can simply get the price by using
some_option.getPrice()
If you want to calculate in other ways, you can use
some_option.getPrice(method='MC',iteration = 500000)
or
some_option.getPrice(method='BT',iteration = 1000)
while MC stands for Monte Carlo and BT stands for Binary Tree.
Project details
Release history Release notifications | RSS feed
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file option-price-0.1.0.tar.gz.
File metadata
- Download URL: option-price-0.1.0.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191030 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fce8f5301b797e8aeb6aa5d5ab2e8fe551c0ad3f6ab72e18182d4c47306ccf8c
|
|
| MD5 |
962095c3fd24553a6b2eb90477f71384
|
|
| BLAKE2b-256 |
e781b4f3795ea7cc1fd68fd7e5004fa31f9c97415e92b18ae8336ebcda9ef5a2
|
File details
Details for the file option_price-0.1.0-py3-none-any.whl.
File metadata
- Download URL: option_price-0.1.0-py3-none-any.whl
- Upload date:
- Size: 4.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.6.0.post20191030 requests-toolbelt/0.9.1 tqdm/4.36.1 CPython/3.7.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f6499e9d8403f168f5ce56a9d38aa51afc1b682f3b0349e9605a61ae0e5aa96c
|
|
| MD5 |
df56c172c0c241eef7829820d7f2ffdb
|
|
| BLAKE2b-256 |
a8b8d1ea53a9b1be1174b174891224d392fce0a9ca6cbc61283494b107a8dd69
|