On Mon, Apr 28, 2014 at 06:39:09AM -0700, Matthew Rocklin wrote:
> When making a predicate on a sympy class should we always use is_foo as in
> is_Real or should we use isfoo as in isinstance? What is the standard
> style for denoting that something is a predicate?
Well, here is an argument from statistics:
$ grep --exclude-dir='mpmath' -R 'def is_[a-z]' sympy/|wc -l
259
vs
$ grep --exclude-dir='mpmath' -R 'def is[a-z]' sympy/
sympy/core/evalf.py:def iszero(mpf, scaled=False):
sympy/utilities/lambdify.py: def isiter(l):
sympy/ntheory/primetest.py:def isprime(n):
sympy/polys/numberfields.py:def isolate(alg, eps=None, fast=False):
It seems, there is no isfoo *methods* at all.