Wednesday, November 4, 2020

The Pylance - Goodbye Kite

Goodbye Kite.

Fast, feature-rich language support for Python in Visual Studio Code

The name Pylance serves as a nod to Monty Python’s Lancelot, who is the first knight to answer the bridge keeper’s questions in the Holy Grail.


(cheers John Cleese et al.)

Expecting Pybrian plugin in the near future :)

The Quntopian has drawn to the close

The Quantopian has been brought to the end but some of their valuable resources have been placed on the github.

[1] Quantopian research 

[2] Community classes 

[3] ... (?)


Saturday, October 3, 2020

Black-Sholes delta


import numpy as np 
from scipy.stats import norm

def delta(flag, s, k, t, r, v): 
  d1 = (np.log(s/k)+(r+v*v/2)*t)/(v*np.sqrt(t)) 
  if flag == “C”:
    return norm.cdf(d1) 
  else: 
    return norm.cdf(-d1) # +signed put delta

Type = ‘C’ # call
S = 97.65 # underlying
K = 100.00 # strike
T = 30/365 # 30 days to expiry (in years)
R = 0.00 # “risk-free” rate
V = 0.12 # 12 vol
delta(Type, S, K, T, R, V)

0.25044822

Type = ‘P’
S = 3000
K = 2900
T = 30/365
R = 0.00
V = 0.20
delta(Type, S, K, T, R, V)

0.27

S = 2950
T = 29/365
delta(Type, S, K, T, R, V)

0.37