| hits_class {polmineR} | R Documentation |
S4 class to represent hits for queries.
Description
S4 class to represent hits for queries.
Usage
## S4 method for signature 'hits'
sample(x, size)
Arguments
x |
A |
size |
A non-negative integer giving the number of items to choose. |
Slots
statA
data.tablewith the following columns:- query
The query (optionally using CQP syntax) that evoked a hit.
- count
Number of matches in corpus/subcorpus.
- freq
Relative frequency of matches in corpus/subcorpus (optional, presence depends on usage of argument
freqof thehitsmethod).- size
Total number of tokens in corpus/subcorpus (optional, presence depends on usage of argument
sizeof thehitsmethod).
If argument
s_attributehas been used in the call of thehitsmethod, thedata.tablewill include additional columns with the s-attributes. The values in the columns will be the values these s-attributes assume. Columnscount,freqandsizewill be based on subcorpora defined by (combinations of) s-attributes.corpusA length-one
"character"vector, ID of the corpus with hits for query or queries.queryObject of class
"character", query or queries forp_attributeThe p-attribute that has been queried, a length-one
charactervector.encodingLength-one
charactervector, the encoding of the corpus.nameLength-one
charactevector, name of the object.