lili4491li
lili4491li

Reputation: 11

Undo stemming after tm::stemDocument()?

I have a list of stemmed words in R. Now, I want to undo my stemming in order to receive a list of all the "complete" words in R.

This is the code I used for stemming my wordlist:

library(tm)

Stemmed.words <- tm_map(Stemmed.words, stemDocument, language = "english") 

But is there a function to reverse the stemming?

Upvotes: 0

Views: 47

Answers (1)

lili4491li
lili4491li

Reputation: 11

I actually found a way to reverse the stemming using the tm package. It provides a fumction stemCompletion, which provides different options to find the original word based on the word-stem. This is very helpful for everyone doing a textual analysis.

Upvotes: 0

Related Questions