I am trying to calculate Lo-Mendell-Rubin likelihood ratio test (LRT) after Latent Profile Analysis using tidyLPA (the distribution of my indicators are non-normal, so the LRT seems preferable). The LRT is not provided by default, however the documentation says it can be calculated as follows:
calc_lrt(n, null_ll, null_param, null_classes, alt_ll, alt_param, alt_classes)
However, I am uncertain where I can retrieve the parameters that need to be specified in the parentheses and where to insert the calc_lrt()-function in my code.
For example, the main part of my code looks like this:
# estimate profiles est.m3.m6.compl_sub1 <- dta2.1[complete.cases(dta2.1$X, dta2.1$Y, dta2.1$Z, dta2.1$V), ] %>% select(c("X", "Y", "Z", "V")) %>% estimate_profiles(1:6, models = c(3, 6) ) est.m3.m6.compl_sub1
# full model indices get_fit(est.m3.m6.compl_sub1) # class estimates get_estimates(est.m3.m6.compl_sub1)
Thank you so much in advance!