Pavia, J. M. “Testing Goodness-of-Fit With the Kernel Density Estimator: GoFKernel”. Journal of Statistical Software, Code Snippets, vol. 66, no. 1, Aug. 2015, pp. 1-27, doi:10.18637/jss.v066.c01.