[SciPy-Dev] factorial2 does not return a float with exact=False

Vincent Davis vincent@vincentdavis....
Mon Jun 28 20:11:08 CDT 2010


According to the docs factorial2 should return a float or int, float
in the case of exact=False, It does not.

>>> import scipy.misc.common as sc
>>> sc.factorial2(7, exact=False)
array(105.00000000000001)
>>> sc.factorial2(7, exact=True)
105L
>>> sc.factorial2(8, exact=True)
384L
>>> sc.factorial2(8, exact=False)
array(384.0)
>>> sc.factorial2(8, exact=False)


More information about the SciPy-Dev mailing list