JeroenDMulder / powRICLPM

powRICLM: Power analysis for the random intercept cross-lagged panel model
https://jeroendmulder.github.io/powRICLPM
Other
4 stars 1 forks source link

negative within correlation #5

Open Eunji23 opened 11 months ago

Eunji23 commented 11 months ago

Thanks for the great package. I want to conduct a simulation study with different conditions from you, but I have got an error message as below;

ℹ Checking arguments... Error in check_within_cor(within_cor) : within_cor must be between 0 and 1: ℹ A correlation is always between 0 and 1. ✖ Your within_cor is -0.42.

I refer to the previous studies about self-esteem and depression, so I need to set up the negative within correlation between two variables in the RI-CLPM. How can I conduct a simulation with this condition through your package?

JeroenDMulder commented 11 months ago

Hi @Eunji23, thank you for spotting this error. That is indeed a mistake. I will correct it and upload a new version of the package to Github (and CRAN). Unfortunately, I can only do this in the first week of November, as my priorities right now are with finishing my PhD dissertation (it has to be handed in October 31st). You could decide to run the power analysis with a within_cor between 0 and 1, although this might not be ideal for your situation.

Eunji23 commented 11 months ago

Thanks for your prompt reply! Good luck with your dissertation.