From 579be3e18a14de90bdfd1c50ef21076d4faa5062 Mon Sep 17 00:00:00 2001 From: Wirawan Purwanto Date: Wed, 2 Oct 2013 15:32:46 -0400 Subject: [PATCH] * errorbar: Added "lazy" string evaluation to speed up errorbar algebra. --- math/stats/errorbar.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/math/stats/errorbar.py b/math/stats/errorbar.py index bb086a8..c327076 100644 --- a/math/stats/errorbar.py +++ b/math/stats/errorbar.py @@ -175,7 +175,7 @@ class errorbar(object): def __str__(self): if getattr(self, "eb", None): return self.eb - elif getattr(self, "eb", None) == None and getattr(self, "ebproc", None) != None: + elif getattr(self, "eb", None) == None and callable(getattr(self, "ebproc", None)): self.eb = self.ebproc(self.val, self.err) return self.eb else: