Skip to contents

Correct Stanford _ST possessive tags by replacing $ with S to make future regex matching easier.

Usage

dtag_possessives(x)

Arguments

x

a character vector of strings, tokenized and with _ST tags.

Value

a character vector of strings, tokenized and with "..$" replaced by "..S"

Examples

x <- c("Their_PRP$", "house_NN", "was_VBD", "big_JJ", "and_CC", "luxurious_JJ", "._.")
dtag_possessives(x)
#> [1] "Their_PRPS"   "house_NN"     "was_VBD"      "big_JJ"       "and_CC"      
#> [6] "luxurious_JJ" "._."