Coder Social home page Coder Social logo

opstrat's People

Contributors

hashabcd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

opstrat's Issues

lot size

hi abhijith,
this is an awesome work. is it possible to add lotsize.

edit: please ignore i got it from example files

access to the resulting figure and axes

I am no good with matplotlib but I wonder if we could have access / full control of the resulting figure to customise or improve it. I tried in a number of different ways but I still get either a new figure or a figure with no axes.

import matplotlib.pyplot as plt
op.multi_plotter(spot=70, spot_range=50, op_list=ls)
print(plt.gcf())

the above code results in:

<Figure size 432x288 with 0 Axes>

Payoff Chart for Target Date.

Thanks a lot for great package. Just looking for an enhancement where we can get payoff chart for target date. Now by default it's for expiry day.

Request for dividend paying equity adjustments

The BSM formula offered in this pip is the standard BSM model. Could you please add support for equities that pay regular dividends where the input 'q' represents the yield?

Example:

import opstrat as op

K = 425			# Strike
r = 1.978		# Risk free rate
t = 35			# Time to expiry (in days)
sigma = 28.84		# Annualized volatility
St = 425.48		# Underlying price
type = 'p'		# Option type (c or p)

bsm=op.black_scholes(K=K, St=St, r=r, t=t, v=sigma, type=type)

q = 3.2			# Dividend
bsm_div=op.black_scholes(K=K, St=St, r=r, t=t, v=sigma, type=type, q=q)

Diagonal and Quantity for each leg support please

Hi, its a great tool! Thank you it works great. Can you please add the ability to add different expiry dates to each leg and quantity for each leg.

Like Friday and Monday - Diagonal

and Selling 1 and Buying 2

Appreciate it!

Future contracts

Hi. It would be nice to add future contracts along with options

Calculate positive and negative areas

Hi, I would like to suggest including a feature to calculate the positive and negative area of accumulated curve.

That would make it easier to compare multiple curves.

Thanks.

yf_plotter using the wrong spot price

The yf_plotter(...) function appears to always use the MSFT spot price regardless of the ticker passed. Thus, the displayed payoff chart always has the wrong spot price which makes the chart way off when prices are either significantly lower or higher than MSFT's.

Example: AMD vertical call spread. Notice that even though AMD's spot price on 6/24/2022 EOD was $87.08, the displayed spot price was $267.70, MSFT's spot price.
image

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.