Using Pers. Dictionary with Aspell in R

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Using Pers. Dictionary with Aspell in R

Ribbis
My goal is to use Aspell 0.60 with a personal dictionary within R.  Running WinXP, R 2.15.1, and Cygwin's install of Aspell 0.60.  Using a test file with 2/5 words misspelled:
SpellTest.txt
test
text
txxt
endeavour
mytzlplk

and dictionary files (aspell.en.pws, and spell.en.prepl respectively) of:
personal_ws-1.1 en 0
mytzlplk

personal_repl-1.1 en 0
mytzlplk superman

and R expression of:
SpellOut<- aspell(SpellTest,
                  program=SpellProg,
                  control=c("--master='en_US.multi' --add-extra-dicts='en_GB.multi' ' -p ./aspell.en.pws'"))

makes no suggestion for "mytzlplk" but finds "txxt" and allows "endeavour."   As seen in:
> print(SpellOut$Suggestions)
[[1]]
 [1] "text"  "TWX"   "TeX"   "Tex"   "tax"   "tux"   "taxi"  "xxxi"
 [9] "xxxv"  "tax's" "tux's"
> summary(SpellOut)
Possibly mis-spelled words:
[1] "mytzlplk" "txxt"

Directly using aspell in the line command within Cygwin terminal finds the personal dictionary just fine:
echo "mytzlplk" | aspell -a --master='en_US.multi' -p ./aspell.en.pws

Not sure how to get R to recognize the personal dictionary file.  Any assistance would be appreciated.  Thanks.