only perform first order transform if total UNIQUE words is greater than 1

Instead of summing up the vector to count total words, count how many entries in the vector are non-zero. This prevents a divide by 0 on line 59 happening in some cases. Not totally sure if this will mess up the algorithm, but I tried to leave things alone as much as possible

Addresses https://github.com/cardmagic/classifier/issues/18