Skip to main content

A Python package for calculating option Greeks and implied volatility.

Project description

volg

A Python package for calculating option Greeks and implied volatility.

Installation

pip install volg

Features

  • Calculate implied volatility (IV) using binary search method
  • Compute option Greeks (Delta, Gamma, Vega, Theta, etc.)
  • Calculate exposures (Delta exposure, Gamma exposure, etc.)
  • Support for both call and put options

Usage

import volg

# Calculate implied volatility
iv = volg.greek.iv(spot_price, strike_price, interest_rate, days_to_expiry, option_price, flag='C')

# Calculate Greeks
greeks = volg.greek.greeks(spot_price, strike_price, interest_rate, days_to_expiry, option_price, flag='C')

# Process a dataframe with option data
df = volg.greek.compute_greeks_vectorized(df)
df = volg.greek.compute_exposure(df)

Alternative import style:

from volg import greek

# Calculate implied volatility
iv = greek.iv(spot_price, strike_price, interest_rate, days_to_expiry, option_price, flag='C')

# Calculate Greeks
greeks = greek.greeks(spot_price, strike_price, interest_rate, days_to_expiry, option_price, flag='C')

License

MIT License

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

volg-0.1.4.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

volg-0.1.4-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file volg-0.1.4.tar.gz.

File metadata

  • Download URL: volg-0.1.4.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.7

File hashes

Hashes for volg-0.1.4.tar.gz
Algorithm Hash digest
SHA256 e4c7bba055f40ad8aa7188bee112073f5195fbb069403b42221ca35cd473999d
MD5 a5707cfcc3afaa91cd54c1714c01d256
BLAKE2b-256 6f1896a49d1b1fc30b5dae3ccbe941357f65ea539b05c5ba4da81fb9e8983499

See more details on using hashes here.

File details

Details for the file volg-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: volg-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.7

File hashes

Hashes for volg-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 86c5da8879e93c14724ce1a85b9bd2facaff3a0d8b4231e2689317af173cca8a
MD5 78b75feee0b524f990af2e304de50cfe
BLAKE2b-256 ed4b309a30c2ce1246060df6dda7508dcfd3acde18131815c22e5bfe80578eb4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page