finished wordCount and charRef metrics calculation