Dear all, thank all of you again for your input. I attach the two versions of the model, which are working best for me, in case anybody ever stumbles across this thread in the future.
The version with the ex post fix of the multimodality in theta
and beta
. For the fix to work, the first document must be to the left (i.e., lower) of the second document in theta
(similar to quanteda::textmodel_wordfish()
). This version worked best for me, may however fail if the simple fix does not generalize to all cases:
wordfish_expost.stan (1.0 KB)
The version with @saudiwin’s method of a positive constrained document and one document which is constrained to be below the first one. The implementation treats the first document as the negative one and the second as the positive one, similar to quanteda::textmodel_wordfish()
. This version also worked well, but was somewhat less efficient (somewhat lower n_eff, higher Rhat).
wordfish_ident.stan (1.4 KB)
Best,
Marko