/DYM

Adds 'Did you mean' feature to the R interactive

Primary LanguageROtherNOASSERTION

Build Status

DYM

Adds 'Did you mean' feature in the R interactive.

Installation

DYM package is now on CRAN! You can install the packege with the following command.

install.packages("DYM")

Otherwise, you can get the latest version of the package from this repository:

#install.packages("devtools")

devtools::install_github("kos59125/DYM")

Examples

> library(DYM)
Run options(error = DYM()) to enable 'Did you mean' feature
> options(error = DYM())
> t_test
Error: object 't_test' not found
Did you mean: 't.test'
> map
Error: object 'map' not found
Did you mean: ['mad', 'Map', 'max']

Hints

If you have ~/.Rprofile file to load on startup, append the following line to enable the feature:

options(error = DYM::DYM())

See help(DYM) for function parameters.

How does this work?

My blog post explains how this package work (in Japanese/日本語).