lexicon_loughran {textdata} | R Documentation |
Loughran-McDonald sentiment lexicon
Description
English sentiment lexicon created for use with financial documents. This lexicon labels words with six possible sentiments important in financial contexts: "negative", "positive", "litigious", "uncertainty", "constraining", or "superfluous".
Usage
lexicon_loughran(
dir = NULL,
delete = FALSE,
return_path = FALSE,
clean = FALSE,
manual_download = FALSE
)
Arguments
dir |
Character, path to directory where data will be stored. If
|
delete |
Logical, set |
return_path |
Logical, set |
clean |
Logical, set |
manual_download |
Logical, set |
Details
Citation info:
This dataset was published in Loughran, T. and McDonald, B. (2011), “When Is a Liability Not a Liability? Textual Analysis, Dictionaries, and 10-Ks.” The Journal of Finance, 66: 35-65.
article{loughran11,
author = {Loughran, Tim and McDonald, Bill},
title = {When Is a Liability Not a Liability? Textual Analysis, Dictionaries, and 10-Ks},
journal = {The Journal of Finance},
volume = {66},
number = {1},
pages = {35-65},
doi = {10.1111/j.1540-6261.2010.01625.x},
url = {https://onlinelibrary.wiley.com/doi/abs/10.1111/j.1540-6261.2010.01625.x},
eprint = {https://onlinelibrary.wiley.com/doi/pdf/10.1111/j.1540-6261.2010.01625.x},
year = {2011}
}
Value
A tibble with 4,150 rows and 2 variables:
- word
An English word
- sentiment
Indicator for sentiment: "negative", "positive", "litigious", "uncertainty", "constraining", or "superfluous"
Source
https://sraf.nd.edu/loughranmcdonald-master-dictionary/
See Also
Other lexicon:
lexicon_afinn()
,
lexicon_bing()
,
lexicon_nrc()
,
lexicon_nrc_eil()
,
lexicon_nrc_vad()
Examples
## Not run:
lexicon_loughran()
# Custom directory
lexicon_loughran(dir = "data/")
# Deleting dataset
lexicon_loughran(delete = TRUE)
# Returning filepath of data
lexicon_loughran(return_path = TRUE)
## End(Not run)