co_occurrence_advance {pubmed.mineR} | R Documentation |
Extracts multiple sentence with co-occurrence of two sets of terms)
Description
Extracts single or multiple sentences with co-occurrence of given terms
Usage
co_occurrence_advance(abstract, term1, term2, n)
Arguments
abstract |
an S4 object of class Abstracts |
term1 |
a character vector of terms |
term2 |
a character vector of terms |
n |
A numeric value, which can be 0,1,2. |
Details
Sentences with co-occurrence of two terms will be extracted along with the corresponding PMIDs. The output will be a data frame. In regard to the argument n, when the value is 0 then the co-occurrence is sought in the same sentence. When the value is 1, then the co-occurrence is sought in two consecutive sentences, namely, first term in the first sentence and second term in the next sentence. When the value is 2, then the co-occurrence is sought in two sentences separated by a sentence without either term1 or term2.
Value
It will return a data frame object containing PMID,sentences and the terms pairs.
Author(s)
Shashwat Badoni Surabhi Seth
See Also
Examples
## Not run: co_occurrence_advance(myabs,"resistance", c("genes","genetic"), 2