Description Usage Arguments Details Value Author(s) See Also Examples
Given a list of entities find all combinations.
1 | pairEntities(data, entity = "Entity")
|
data |
A tbl created by extractSentenceInfo |
entity |
The name of the column holding entity |
Given a list of entities find all combinations. This expects the data to be of the form |Entity|Type|Start|Stop| as created by extractSenetenceInfo.
A two-column tbl like a pair list between the entities found together
Jared P. Lander
extractSentenceInfo
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
ner_model_path <- "mitie/MITIE-models/english/ner_model.dat"
ner <- NamedEntityExtractor$new(ner_model_path)
textFiles <- file.path('data', 'NYTimes', dir('data/NYTimes/'))
thisText <- readLines(textFiles[1])
sentences <- sent_detect(thisText)
# run on just one sentence
oneSent <- extractSentenceInfo(sentences[1], nerModel=ner)
pairEntities(oneSent)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.