Apply rules

apply_rules(word, name, steprules)

Arguments

word

word to which you want to apply the rules

name

the rule name, possible values are: 'Plural', 'Feminine', 'Adverb', 'Augmentative', 'Noun', 'Verb', 'Vowel' .

steprules

steprules as obtained from the function extract_rules.

Examples

steprules <- readRDS(system.file("steprules.rds", package = "rslp")) rslp:::apply_rules("balões", name = "Plural", steprules)
#> [1] "balão"
rslp:::apply_rules("lápis", name = "Plural", steprules)
#> [1] "lápis"
rslp:::apply_rules("bolas", name = "Plural", steprules)
#> [1] "bola"