joelgrus / data-science-from-scratch

code for Data Science From Scratch book
MIT License
8.71k stars 4.52k forks source link

Update naive_bayes.py #98

Closed faisito closed 4 years ago

faisito commented 4 years ago

the function drop_final_s is not needed (not used anywhere else in the code)

def drop_final_s(word): return re.sub("s$", "", word)

faisito commented 4 years ago

I take back my comment. The code appears later in the chapter (p.183), on how to improve the model. Apologies