mercredi 1 juillet 2015

scipy.stats.anderson(tail, dist='gumbel') fails with tail = numpy.random.gumbel(size=50)

title says it all. I'm puzzled why the Anderson-Darling test implementation in scipy.stats says that the variates generated by numpy.random do not fit the underlining distribution. Any help?

numpy.random.seed(0)
tail = numpy.random.gumbel(size=50)
scipy.stats.anderson(tail, dist='gumbel')

output is:

(3.6111131596040948, array([ 0.461,  0.619,  0.736,  0.853,  1.009]), array([ 25. ,  10. ,   5. ,   2.5,   1. ]))

Since A2 is larger than the critical values, that output means that my data is not Gumbel distributed.

Why is that? The data generated by random.gumbel should be gumbel distributed =/




Aucun commentaire:

Enregistrer un commentaire