Last active
August 24, 2018 08:37
-
-
Save Vayel/d5c22bdd0f6f18b1612d563322ef0031 to your computer and use it in GitHub Desktop.
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 numpy as np | |
import matplotlib.pyplot as plt | |
from scipy.stats import kstwobign | |
d_min, d_max = kstwobign.ppf(0.01), kstwobign.ppf(0.99) | |
d_vals = np.linspace(d_min, d_max, num=100) | |
cdf = kstwobign.cdf(d_vals) | |
fig, ax = plt.subplots() | |
ax.plot(d_vals, cdf, '-') | |
ax.set_xlabel('d') | |
ax.set_ylabel('CDF') | |
ax.spines['right'].set_visible(False) | |
ax.spines['top'].set_visible(False) | |
ax.set_xlim([d_min, d_max]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment