Low level spell checker and morphological analyzer based on the famous 'hunspell' library < https://hunspell.github.io>. The package can analyze or check individual words as well as parse text, latex, html or xml documents. For a more user-friendly interface use the 'spelling' package which builds on this package to automate checking of files, documentation and vignettes in all common formats.
languages with rich morphology and complex word compounding or character encoding. The package can check and analyze individual words as well as search for incorrect words within a text, latex, html or xml document. Use the 'devtools' package to spell check R documentation with 'hunspell'.
This package includes a bundled version of libhunspell and no longer depends on external system libraries:
About the R package:
# Check individual wordswords <- c("beer", "wiskey", "wine")correct <- hunspell_check(words)print(correct)# Find suggestions for incorrect wordshunspell_suggest(words[!correct])# Extract incorrect from a piece of textbad <- hunspell("spell checkers are not neccessairy for langauge ninja's")print(bad[])hunspell_suggest(bad[])# Stemmingwords <- c("love", "loving", "lovingly", "loved", "lover", "lovely", "love")hunspell_stem(words)hunspell_analyze(words)
devtools package uses this package to spell R package documentation:
# Spell check a packagelibrary(devtools)spell_check("~/mypackage")