PlackettLuce Wrapper for Model-based Recursive Partitioning
This is a wrapper around PlackettLuce
as required by
mob
for model-based recursive partitioning. It is
not intended for general use.
plfit( y, x = NULL, ref = 1L, start = NULL, weights = NULL, offset = NULL, ..., estfun = FALSE, object = FALSE )
y |
a |
x |
unused. |
ref |
An integer or character string specifying the reference item (for
which log worth will be set to zero). If |
start |
starting values for the worth parameters and the tie parameters
on the raw scale (worth parameters need not be scaled to sum to 1). If
|
weights |
an optional vector of weights for each ranking. |
offset |
unused. |
... |
additional arguments passed to |
estfun |
logical. If |
object |
logical. If |
a list with elements
coefficients |
model coefficients. |
objfun |
the negative log-likelihood. |
estfun |
if |
object |
if |
# rankings R <- matrix(c(1, 2, 0, 0, 4, 1, 2, 3, 2, 1, 1, 1, 1, 2, 3, 0, 2, 1, 1, 0, 1, 0, 3, 2), nrow = 6, byrow = TRUE) colnames(R) <- c("apple", "banana", "orange", "pear") R <- as.rankings(R) # group rankings into two groups G <- group(R, rep(1:2, 3)) # plfit() gives the same results as PlackettLuce() pl <- plfit(G) pl$coefficients -pl$objfun mod <- PlackettLuce(R) coef(mod) logLik(mod)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.