[Scipy-svn] r7048 - branches/0.9.x/scipy/stats
scipy-svn at scipy.org
scipy-svn at scipy.org
Sat Jan 15 09:04:18 EST 2011
Author: rgommers
Date: 2011-01-15 08:04:18 -0600 (Sat, 15 Jan 2011)
New Revision: 7048
Modified:
branches/0.9.x/scipy/stats/distributions.py
Log:
stats.distributions, add argcheck to moment method, fixes ticket:934
Modified: branches/0.9.x/scipy/stats/distributions.py
===================================================================
--- branches/0.9.x/scipy/stats/distributions.py 2011-01-15 14:03:48 UTC (rev 7047)
+++ branches/0.9.x/scipy/stats/distributions.py 2011-01-15 14:04:18 UTC (rev 7048)
@@ -5464,6 +5464,8 @@
instance object for more information)
"""
+ if not self._argcheck(*args):
+ return nan
if (floor(n) != n):
raise ValueError("Moment must be an integer.")
if (n < 0): raise ValueError("Moment must be positive.")
More information about the Scipy-svn
mailing list