[Spambayes-checkins] spambayes hammie.py,1.13,1.14
Guido van Rossum
gvanrossum@users.sourceforge.net
Sat, 07 Sep 2002 19:59:45 -0700
Update of /cvsroot/spambayes/spambayes
In directory usw-pr-cvs1:/tmp/cvs-serv31886
Modified Files:
hammie.py
Log Message:
Make -u only print the spams.
Index: hammie.py
===================================================================
RCS file: /cvsroot/spambayes/spambayes/hammie.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** hammie.py 7 Sep 2002 17:12:22 -0000 1.13
--- hammie.py 8 Sep 2002 02:59:43 -0000 1.14
***************
*** 253,263 ****
prob, clues = bayes.spamprob(tokenize(msg), True)
isspam = prob >= 0.9
- print "%6d %4.2f %1s" % (i, prob, isspam and "S" or "."),
if isspam:
spams += 1
print formatclues(clues)
else:
hams += 1
- print
print "Total %d spam, %d ham" % (spams, hams)
--- 253,262 ----
prob, clues = bayes.spamprob(tokenize(msg), True)
isspam = prob >= 0.9
if isspam:
spams += 1
+ print "%6s %4.2f %1s" % (i, prob, isspam and "S" or "."),
print formatclues(clues)
else:
hams += 1
print "Total %d spam, %d ham" % (spams, hams)