Skip to content

Instantly share code, notes, and snippets.

@GermanCM
Created June 17, 2020 07:11
Show Gist options
  • Save GermanCM/61f1f499d28adcb08c9b66114ae7a966 to your computer and use it in GitHub Desktop.
Save GermanCM/61f1f499d28adcb08c9b66114ae7a966 to your computer and use it in GitHub Desktop.
Visual normality check
from statsmodels.graphics.gofplots import qqplot
from matplotlib import pyplot
# q-q plot
sample_normal = normal(size=1000)
qqplot(sample_normal, line='s')
qqplot(sample, line='s')
pyplot.show()
@GermanCM
Copy link
Author

'sample_normal' is a normal distribution of values which we expect to be normal; the input values in a real case would be the series of values to be evaluated

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment