Closed barracuda156 closed 1 year ago
I don't quite know why that would happen, but it's not an issue with MplusAutomation per se. The package dependency checks happen as a standard part of package installation and are handled at the base R level. I wonder if the .libPaths()
for your installation are not correct and do not point to the location of where MacPorts placed fastDummies? I'd try library(fastDummies)
in an R session and also installed.packages()["fastDummies",]
to see if R registers the package installation and location.
Hope this helps, Michael
@michaelhallquist Thank you, you are right, something is broken with fastDummies
:
> library(fastDummies)
Error in library(fastDummies) : there is no package called ‘fastDummies’
Could you say where libPaths
are usually set? It turned out that several packages are broken in this manner (not many, but more than one).
If you have non-standard locations for your R packages, you can use the .libPaths function. For example, in my lab, we use this to have a central location for all packages. I place this code in ~/.Rprofile
so that it runs when R starts:
rv <- R.Version()
if (rv$major == "4" && rv$minor == ".0.3") {
lab_packages <- "/proj/mnhallqlab/lab_resources/lab_rpackages_v403"
} else if (rv$major == "4" && rv$minor == ".1.2") {
lab_packages <- "/proj/mnhallqlab/lab_resources/lab_rpackages_v412"
} else if (rv$major == "4" && rv$minor == ".2.1") {
lab_packages <- "/proj/mnhallqlab/lab_resources/lab_rpackages_v421"
} else {
lab_packages <- NULL
}
if (!is.null(lab_packages) && !lab_packages %in% .libPaths()) { .libPaths(c(lab_packages, .libPaths())) }
Any idea what this means? (Sorry, should have checked this straight-away, this sounds at least more specific.)
> installed.packages()["fastDummies",]
Error in installed.packages()["fastDummies", ] : subscript out of bounds
Probably that R doesn't see the package at all at the moment. You can drop the row subset to see all installed packages: installed.packages()
Probably that R doesn't see the package at all at the moment. You can drop the row subset to see all installed packages:
installed.packages()
@michaelhallquist Found the reason, thank you again.
P. S. For anyone bumping into this: https://trac.macports.org/ticket/67299
I get this when running check:
Yet it is installed in fact:
Any idea why it cannot find specifically this dependency?