when lme() model contain a categorical variable, coefs() won't run properly
here is the sample code for repetition in version 2.3.0.1
library(dplyr)
library(nlme)
iris = iris |>
mutate(Category2 = as.character(round(Sepal.Length,0)))
mod1 = lme(Sepal.Width ~ Petal.Length + Petal.Width + Category2,
random = ~1|Species, data = iris)
mod2 = psem(mod1)
summary(mod2)
it will return if (random) {conditions >1
i think this is caused by the function model.frame(), it pass data to random
when lme() model contain a categorical variable, coefs() won't run properly
here is the sample code for repetition in version 2.3.0.1
it will return
if (random) {conditions >1i think this is caused by the function
model.frame(), it passdatatorandom