This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import datetime | |
import tushare as ts | |
import numpy as np | |
from math import log,sqrt,exp | |
from scipy import stats | |
import plotly.graph_objects as go | |
import plotly | |
import plotly.express as px |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<body bgcolor=000000> | |
<table boder=0 cellpadding=0 cellspacing=0> | |
<tr height=3> | |
<td width=3 bgcolor=888888 rowspan=105></td> | |
<td bgcolor=888888 colspan=54></td> | |
<td width=3 bgcolor=888888 rowspan=105></td> | |
</tr> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <cmath> | |
#include <tuple> | |
// Copyright (c) <2020> <TouhouSupport(Ameame)> | |
// "Anti 996" License Version 1.0 (Draft) | |
// Permission is hereby granted to any individual or legal entity | |
// obtaining a copy of this licensed work (including the source code, | |
// documentation and/or related items, hereinafter collectively referred | |
// to as the "licensed work"), free of charge, to deal with the licensed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import math | |
import numpy | |
import matplotlib.pyplot | |
import scipy.stats | |
def d1(S0, K, r, sigma, T): | |
return (math.log(S0 / K) + (r + sigma**2 / 2) * T) / (sigma * math.sqrt(T)) | |
def d2(S0, K, r, sigma, T): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import abc | |
from math import exp | |
import math | |
import numbers | |
import time | |
import numpy as np | |
import scipy.optimize | |
import scipy.stats |