Scaling Models and Classifiers for Textual Data

Scaling models and classifiers for sparse matrix objects representing textual data in the form of a document-feature matrix. Includes original implementations of 'Laver', 'Benoit', and Garry's (2003) , 'Wordscores' model, the Perry and 'Benoit' (2017) class affinity scaling model, and the 'Slapin' and 'Proksch' (2008) 'wordfish' model, as well as methods for correspondence analysis, latent semantic analysis, and fast Naive Bayes and linear 'SVMs' specially designed for sparse textual data.


quanteda.textmodels

Downloads TotalDownloads R-CMD-check Codecov testcoverage

About

An R package adding text scaling models and classifiers for quanteda. Prior to quanteda v2, many of these were part of that package. Early development was supported by the European Research Council grant ERC-2011-StG 283794-QUANTESS.

For more details, see https://quanteda.io.

How to Install

You can install it via the normal way from CRAN, using your R GUI or

install.packages("quanteda.textmodels") 

Or for the latest development version:

# devtools package required to install quanteda from Github 
remotes::install_github("quanteda/quanteda.textmodels") 

Because this compiles some C++ and Fortran source code, you will need to have installed the appropriate compilers. On Windows platform, this means the Rtools software available from CRAN, or the macOS tools from macOS tools, including namely the Clang 6.x compiler and the GNU Fortran compiler (as quanteda requires gfortran to build). If you are still getting errors related to gfortran, follow the fixes here.

How to cite

Benoit, Kenneth, Kohei Watanabe, Haiyan Wang, Paul Nulty, Adam Obeng, Stefan Müller, and Akitaka Matsuo. (2018) “quanteda: An R package for the quantitative analysis of textual data”. Journal of Open Source Software. 3(30), 774. https://doi.org/10.21105/joss.00774.

For a BibTeX entry, use the output from citation(package = "quanteda").

Leaving Feedback

If you like quanteda, please consider leaving feedback or a testimonial here.

Contributing

Contributions in the form of feedback, comments, code, and bug reports are most welcome. How to contribute:

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("quanteda.textmodels")

0.9.10 by Kenneth Benoit, 2 years ago


https://github.com/quanteda/quanteda.textmodels


Browse source code at https://github.com/cran/quanteda.textmodels


Authors: Kenneth Benoit [cre, aut, cph] , Kohei Watanabe [aut] , Haiyan Wang [aut] , Patrick O. Perry [aut] , Benjamin Lauderdale [aut] , Johannes Gruber [aut] , William Lowe [aut] , Vikas Sindhwani [cph] (authored svmlin C++ source code) , European Research Council [fnd] (ERC-2011-StG 283794-QUANTESS)


Documentation:   PDF Manual  


GPL-3 license


Imports glmnet, Matrix, quanteda, RSpectra, Rcpp, stringi

Depends on methods

Suggests ca, covr, fastNaiveBayes, knitr, lsa, microbenchmark, naivebayes, quanteda.textplots, spelling, testthat, rmarkdown

Linking to Rcpp, RcppArmadillo, quanteda


Imported by minorparties.

Suggested by explor, grafzahl, oolong, quanteda.textplots, rainette.


See at CRAN