Question regarding running LPA using split data

35 views
Skip to first unread message

Haram Kim

unread,
Dec 19, 2019, 11:11:37 PM12/19/19
to tid...@googlegroups.com
To the group,

I'm reaching out today to ask you a question on the tidyLPA. I've reached out before and you've helped me so well that I was able to submit a paper. A problem occurred as I was addressing the revision points, the reviewers told me to split a dataset I have into two and test the LPA to see if the profiles are replicated.

So I divided the files using the following code:

sample_size = floor(0.5*nrow(k))
set.seed(777)

picked = sample(seq_len(nrow(k)), size = sample_size)

k1 = k[picked,]
k2 = k[-picked,]

Then, ran the tidyLPA again and got the following error:

Error in MclustBootstrap(out$model, nboot = 100, type = "bs", verbose = FALSE) :
  object must be of class 'Mclust' or 'densityMclust'

I wonder if the error is caused by the splitting of the dataset or from the tidyLPA itself.

Following up on this, I split file in SPSS and the following error keeps come up: Error in mdpwst[i]:mdpwfin[i] : NA/NaN argument

I'd really appreciate it if you could advise me on this issue. Thank you in advance for your help!

Best,
Julia

Caspar van Lissa

unread,
Dec 20, 2019, 2:34:07 AM12/20/19
to tidyLPA
Dear Julia, based on the error message, I'm 99% sure that you're using an old version of tidyLPA. Could you please install the latest version from CRAN, or even the development version by running devtools::install_github("cjvanlissa/tidyLPA")?

Furthermore, this is an mclust error,and may signify nonconvergence. How many cases are in the split file, which model are you running, and are the data continuous or Likert-type?

Julia

unread,
Dec 27, 2019, 1:51:36 AM12/27/19
to tidyLPA
Dear Caspar,

Thank you so much for the response. To answer your question, each split files are about 1200 cases and are continuous. 

2019년 12월 20일 금요일 오후 4시 34분 7초 UTC+9, Caspar van Lissa 님의 말:
Reply all
Reply to author
Forward
0 new messages