textmodel_wordscores implements Laver, Benoit and Garry's (2003) 
wordscores method for scaling of a single dimension.  This can be called
directly, but the recommended method is through textmodel.textmodel_wordscores(data, scores, scale = c("linear", "logit"), smooth = 0)## S3 method for class 'textmodel_wordscores_fitted':
predict(object, newdata = NULL,
  rescaling = "none", level = 0.95, verbose = TRUE, ...)
## S3 method for class 'textmodel_wordscores_fitted':
print(x, n = 30L, digits = 2, ...)
## S3 method for class 'textmodel_wordscores_fitted':
show(object)
## S3 method for class 'textmodel_wordscores_predicted':
show(object)
## S3 method for class 'textmodel_wordscores_predicted':
print(x, ...)
refDatanone for "raw" scores; lbg for LBG (2003) 
rescaling; or mv for the rescaling proposed by Martin and Vanberg 
(2007).  (Note to authors: Provide full details here in documentation.)TRUE, output status messagespredict method for a wordscores fitted object returns a 
  data.frame whose rows are the documents fitted and whose columns contain 
  the scored textvalues, with the number of columns depending on the options 
  called (for instance, how many rescaled scores, and whether standard errors
  were requested.)  (Note: We may very well change this soon so that it is a 
  list similar to other existing fitted objects.)textmodel_wordscores results in an object of class 
textmodel_wordscores_fitted containing the
following slots:Beauchamp, N. 2012. "Using Text to Scale Legislatures with Uninformative Voting." New York University Mimeo.
Martin, L W, and G Vanberg. 2007. "A Robust Transformation Procedure for Interpreting Political Text." Political Analysis 16(1): 93-100.
Laver, Michael, Kenneth R Benoit, and John Garry. 2003. "Extracting Policy Positions From Political Texts Using Words as Data." American Political Science Review 97(02): 311-31.
Martin, L W, and G Vanberg. 2007. "A Robust Transformation Procedure for Interpreting Political Text." Political Analysis 16(1): 93-100.
(ws <- textmodel(LBGexample, c(seq(-1.5, 1.5, .75), NA), model="wordscores"))
predict(ws)
predict(ws, rescaling="mv")
predict(ws, rescaling="lbg")
# same as:
(ws2 <- textmodel_wordscores(LBGexample, c(seq(-1.5, 1.5, .75), NA)))
predict(ws2)Run the code above in your browser using DataLab