KJKan / mcfarland

This is a short tutorial on how to compare latent factor models and psychometric network models using the R package Psychonetrics (Epskamp, 2020).
9 stars 4 forks source link

Error in samplestats_norawts(...) : 'nobs' must be a vector with sample size per group #2

Open reetakankaanpaa opened 2 years ago

reetakankaanpaa commented 2 years ago

Hi,

thank you for the excellent example syntax to compare lvm and networks. however, when I try to write my own syntax, I get halted by this error message. I don't know what to do, since my nobs = n_data is indeed a 1*1 vector meaning sample size.

KJKan commented 2 years ago

Hi,

Thanks for trying out!

Could it be the case that your input is actually a list? If so, then psychonetrics expects a list for nobs as well.

Best, Kees-Jan

KJKan commented 1 year ago

If your correlation matrix is defined a data.frame change it into a matrix.