Git Product home page Git Product logo

vollib

vollib is a python library for calculating option prices, implied volatility and greeks. At its core is Peter Jäckel's source code for LetsBeRational, an extremely fast and accurate algorithm for obtaining Black's implied volatility from option prices.

Building on this solid foundation, vollib provides functions to calculate option prices, implied volatility and greeks using Black, Black-Scholes, and Black-Scholes-Merton. vollib implements both analytical and numerical greeks for each of the three pricing formulae.

About the initial release

This is the initial release of vollib. Tests and documentation are still incomplete.

Dependencies

vollib was written in Python 2.7. It depends on the lets_be_rational package, a simple (SWIG) wrapper around Peter Jäckel's original C source code.

To install via pip, type the following:

>>> pip install vollib

Installing vollib via pip will automatically install the necessary dependencies, except for SWIG, pip, and Python. This has been tested to work on Windows, Linux and Macintosh OS X.

Python, pip and SWIG must be installed prior to installing vollib.

lets_be_rational is quite stable compared to vollib, which is likely to be updated frequently.

For those who wish to clone the vollib repo, you might prefer to install lets_be_rational separately with pip, since this takes care of the C compilation.

About "Let's be Rational":

"Let's Be Rational" is a paper by Peter Jäckel showing "how Black's volatility can be implied from option prices with as little as two iterations to maximum attainable precision on standard (64 bit floating point) hardware for all possible inputs."

The paper is accompanied by the full C source code, which resides at www.jaeckel.org/LetsBeRational.7z.

Copyright © 2013-2014 Peter Jäckel.

Permission to use, copy, modify, and distribute this software is freely granted,
provided that this notice is preserved.

WARRANTY DISCLAIMER
The Software is provided "as is" without warranty of any kind, either express or implied,
including without limitation any implied warranties of condition, uninterrupted use,
merchantability, fitness for a particular purpose, or non-infringement.

Links:

vollib's Projects

vollib icon vollib

Fundamentally a swig/python wrapper around Peter Jaeckel's lets_be_rational. lets_be_rational focuses exclusively on Black76, while Vollib extends this to add support for Black-Scholes and Black-Scholes-Merton.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.