Closed isaactpetersen closed 2 years ago
Thanks for the reprex, it helped me verify this had nothing to do with conflicts between semTools
and the mountain of other packages in your path. I found the same problem after loading only semTools
(which already loads lavaan
) and excluding the unnecessary (in this case) missing=
argument. Using debug()
, I found that there was no problem running parallel::mclapply()
, but it returned more informative errors for each node:
[1] Error in get(as.character(FUN), mode = "function", envir = envir):
object 'permuteOnce.mgcfa' of mode 'function' was not found
I have been unable to locate a NEWS file stating a change to whether mclapply(FUN=)
can accept a character
string naming a function (as lapply(FUN=)
and parallel::parLapply()
still can), but I swear I have used permuteMeasEq()
with parallel="multicore"
on my own computer multiple times in the past. Currently, the mclapply()
help page simply states it must be a function, stating nothing about (back)quoted names. So I have updated permuteMeasEq()
to convert the paste()
d string to as.name()
before passing it to mclapply()
, and that works on your reprex. Hopefully, you have no problem installing the development version of semTools
on your cluster.
Wonderful, thanks very much for your help with that, Terrence! Much appreciated.
I'm receiving the following error when trying to use
permuteMeasEq()
:Error: $ operator is invalid for atomic vectors
I'm using semTools_0.5-5 on a Linux cluster. Below is the code:
Below is my
sessionInfo()
: