choose_best | R Documentation |
Chooses latent dimension that best predicts the outcome.
choose_best(
x,
bestmin = 0,
othermax = 0,
ndim = NULL,
terms = NULL,
nperterm = NULL,
...
)
x |
A #Votes x #Dimensions matrix of PRE values. |
bestmin |
Scalar indicating the minimum PRE value to be considered "well predicted" bythe model. |
othermax |
Scalar indicating the maximum PRE of the inferior dimension.
If |
ndim |
Scalar giving the number of dimensions to use. The algorithm
will use the first |
terms |
Vector indicating the term to which each bill belongs. |
nperterm |
Scalar giving the number of bills to use per term.
If |
... |
Other arguments to be passed down - currently not implemented. |
The algorithm chooses the best dimension by identifying for each vote the
situation where the pre for variable j is greater than bestmin
and
the pre for all other variables not equal to j is less than othermin
.
A vector identifying which dimension was best or NA
if no dimension met both criteria.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.