0
$\begingroup$

I have estimated an ordered logistic regression with the vglm function of the VGAM package in R.

Here is a minimalistic example of what I did:

library(VGAM)

cdata <- data.frame(y = ordered(as.factor(rep(1:3, 1000))), 
                   x1 = rnorm(3000,50,1), 
                   x2 = rbinom(3000, 1, 0.4), 
                group = sort(rep(1:100,10)))

orderedlogit <- vglm(y ~ x1 + x2, cumulative(parallel = FALSE), cdata)

Now I would like to estimate cluster robust standard errors for the groups defined by the group variable.

I have tried the package lmtest in combination with sandwich since it is compatible with polr as described in this post, but for vglm it gives the following error:

Error in UseMethod("estfun") : no applicable method for 'estfun' applied to an object of class "c('vglm', 'vlm', 'vlmsmall')"

Does anyone know how to get cluster robust standard errors for a vglm object?

$\endgroup$
2
  • $\begingroup$ I don't think vglm has an option for that. But, GEE type estimation for multinomial outcomes are implemented in the R package multgee. $\endgroup$
    – aphe
    Commented Apr 27, 2021 at 13:16
  • $\begingroup$ Thank you! I will have a look at that package as well. $\endgroup$
    – Nerd
    Commented Apr 27, 2021 at 21:45

1 Answer 1

0
$\begingroup$

In the end I switched to Stata and used the user-written gologit2 package.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.