Various changes

Changed the TF-IDF weighting to focus on features of individual data
nodes instead of treating class nodes as documents. Updated example for
cosine similarity.