public TermDocumentMatrix rejectStopWords(final TermDocumentMatrix matrix) {
TermDocumentMatrix tdm = matrix;
tdm = tdm.toLowerCase();
assertEquals(9, tdm.documentCount());
assertEquals(42, tdm.termCount());
tdm = tdm.rejectHapaxes();
assertEquals(9, tdm.documentCount());
assertEquals(16, tdm.termCount());
tdm = tdm.toLowerCase().rejectStopwords();
assertEquals(9, tdm.documentCount());
assertEquals(12, tdm.termCount());