Skip to content

replace_word_elongations creates NAs #61

@erhard1

Description

@erhard1

I was doing some text clean up with replace_word_elongations and ran into a case where the phrase "AAA battery" caused all word elongation matches to become NA. I modified the example from the help file to show the situation:

x <- c('look', 'noooooo!', 'real coooool!', "it's sooo goooood", 'fsdfds',
'fdddf', 'as', "aaaahahahahaha", "aabbccxccbbaa", 'I said heyyy!',
"I'm liiiike whyyyyy me?", "Wwwhhatttt!", "AAA battery")

replace_word_elongation(x)
[1] "look" NA NA NA "fsdfds" NA "as" NA
[9] "aabbccxccbbaa" NA NA NA NA

Thanks in advance for any help you can provide. I have been pleased with how the textclean package has been working so far.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions