| rating.emmeans {RVAideMemoire} | R Documentation |
EMMeans for Cumulative Link (Mixed) Models
Description
Extracts EMMeans (produced by emmeans) from Cumulative Link (Mixed) Models (produced by clm or clmm), with different possible formats.
Usage
rating.emmeans(emm, type = c("prob", "cumprob", "class1", "class2"), level = 0.9)
Arguments
emm |
|
type |
type of output to be returned: |
level |
used only for type |
Details
A factor named cut must have been called in emmeans, to compute EMMeans per cut point (i.e. rating). Additionally, the argument mode of emmeans must have been set to "linear.predictor". Finally, the call to emmeans is typically like emmeans(model,~factor|cut,mode="linear.predictor") where factor is the factor (or interaction) giving levels for which EMMeans have to be computed.
Author(s)
Maxime HERVE <maxime.herve@univ-rennes1.fr>
See Also
Examples
require(ordinal)
require(emmeans)
model <- clm(rating~contact*temp,data=wine)
EMM <- emmeans(model,~contact:temp|cut,mode="linear.predictor")
# Probabilities
rating.emmeans(EMM)
# Cumulative probabilities
rating.emmeans(EMM,type="cumprob")
# Most probable rating
rating.emmeans(EMM,type="class1")