1

I am using qdap package for spell checking, but the default dictionary doesn't have many words such as cities,states, countries, or languages. I know I can add words to the dictionary like below

dict <- c(qdapDictionaries::GradyAugmented, "word1","word2","word3")

But I was wondering if there is a more efficient way to add about 1000 words to the dictionary.

Thanks

  • 3
    Could you be more precise about what you want to achieve? Where do you get your new words from? I'd say you could just put them into a character vector `v`, and then do `dict <- c(qdapDictionaries::GradyAugmented, v)`. Is there an efficiency problem with that? – Scarabee Jul 03 '17 at 22:48
  • Perfect, thanks! This answers my question. – Monica Muller Jul 03 '17 at 22:59
  • 2
    You could have your words in a .csv file or so, read it into a vector and use it as Scarabee says. – Indi Jul 04 '17 at 06:12

0 Answers0