# Negative Opinion Words

> A [list][sentiment-lexicon] of negative opinion words.


<section class="usage">

## Usage

``` javascript
var words = require( '@stdlib/datasets/liu-negative-opinion-words-en' );
```

#### words()

Returns a [list][sentiment-lexicon] of negative opinion words.

``` javascript
var list = words();
/* returns
    [
        '2-faced',
        '2-faces',
        'abnormal',
        'abolish',
        'abominable',
        'abominably',
        'abominate',
        'abomination',
        'abort',
        'aborted',
        'aborts',
        'abrade',
        'abrasive',
        ...
    ]
*/
```

</section>

<!-- /.usage -->


<section class="notes">

## Notes

* A word's appearance in a sentence does __not__ necessarily imply a positive or negative opinion. See [Liu (2010)](#references).
* The list includes misspelled words. Their presence is intentional, as such misspellings frequently occur in social media content.

</section>

<!-- /.notes -->


<section class="examples">

<!-- TODO: more creative example; possibly counting the number of negative words per sentence in two pieces of text. -->

## Examples

``` javascript
var floor = require( '@stdlib/math/base/special/floor' );
var randu = require( '@stdlib/math/base/random/randu' );
var words = require( '@stdlib/datasets/liu-negative-opinion-words-en' );

var list = words();
var len = list.length;
var idx;
var i;

// Select random words from the list...
for ( i = 0; i < 100; i++ ) {
    idx = floor( randu()*len );
    console.log( list[ idx ] );
}
```

</section>

<!-- /.examples -->


---

<section class="cli">

## CLI

<section class="usage">

### Usage

``` bash
Usage: liu-negative-opinion-words-en [options]

Options:

  -h,    --help                Print this message.
  -V,    --version             Print the package version.
```

</section>

<!-- /.usage -->


<section class="examples">

### Examples

``` bash
$ liu-negative-opinion-words-en
2-faced
2-faces
abnormal
abolish
...
```

</section>

<!-- /.examples -->

</section>

<!-- /.cli -->


---

<section class="references">

## References

* Hu, Minqing and Liu, Bing (2004). "Mining and Summarizing Customer Reviews." *Proceedings of the ACM SIGKDD International Conference on Knowledge Discovery and Data Mining* (KDD-2004), Aug 22-25, Seattle, Washington, USA.
* Liu, Bing, Hu, Minqing, and Cheng, Junsheng (2005). "Opinion Observer: Analyzing and Comparing Opinions on the Web." *Proceedings of the 14th International World Wide Web Conference* (WWW-2005), May 10-14, Chiba, Japan.
* Liu, Bing (2010). "Sentiment Analysis and Subjectivity." *Handbook of Natural Language Processing, Second Edition*. Ed. Nitin Indurkhya, Ed. Fred J. Damerau. Boca Raton: Chapman and Hall/CRC. 627-66. Print.

</section>

<!-- /.references -->


<!-- <license> -->

## License

The data files (databases) are licensed under an [Open Data Commons Attribution 1.0 License][odc-by-1.0] and their contents are licensed under a [Creative Commons Attribution 4.0 International Public License][cc-by-4.0]. The original dataset is attributed to Bing Liu and Minqing Hu and can be found [here][sentiment-lexicon]. The software is licensed under [Apache License, Version 2.0][apache-license].

<!-- </license> -->


<section class="links">

[sentiment-lexicon]: http://www.cs.uic.edu/~liub/FBS/sentiment-analysis.html#lexicon
[odc-by-1.0]: http://opendatacommons.org/licenses/by/1.0/
[cc-by-4.0]: http://creativecommons.org/licenses/by/4.0/
[apache-license]: https://www.apache.org/licenses/LICENSE-2.0

</section>

<!-- /.links -->
