"cannot coerce type 'closure' to vector of type 'character'" - when running 'clmm' comand from "ordinal" package in R

38 views Asked by At

I run a command from the paper "Multilevel Ordinal Logit Models: A Proportional Odds Application Using Data from Brazilian Higher Education Institutions" - from the supplementary material:

ord_gllamm <- clmm(formula = classes ~ year  + rate_doctstudents_prof + is_federal  + (1|hei_code),
                   data = df,
                   Hess = T,
                   nAGQ = 10)

and I got this error:

Error in as.character(sys.call(sys.parent())[[1L]]) : 
  cannot coerce type 'closure' to vector of type 'character'

I tried to change the type of "classes", but it didn't help. Any help is appreciated. Thanks

I looked for similar questions, and I tried to change the type of the output variable. I looked for spelling problems, and ran similar code on different data frame, but got the same error.

0

There are 0 answers