cnfoley / hyprcoloc

R package for performing high dimensional multi-trait colocalization analyses using GWAS summary data
39 stars 10 forks source link

Can't Install hyprcoloc on R 4.4.0 #13

Closed koripainchaud closed 2 months ago

koripainchaud commented 3 months ago

Hi,

I am having issues installing the hyprcoloc R package using R 4.4.0 with the commands provided in the README file:

install_github("jrs95/hyprcoloc", build_opts = c("--no-resave-data", "--no-manual"), build_vignettes = TRUE) install_github("cnfoley/hyprcoloc", build_opts = c("--resave-data", "--no-manual"), build_vignettes = TRUE)

I have attached the .Rout files which include the full errors for the installation. install-hyprcoloc-c++-Rout.txt install-hyprcoloc-Rout.txt

I sanitized the name of the home directory to be LINUX-USERNAME.

The first error in the logs are the following:

align2.cpp:180:20: error: cannot convert ‘Eigen::internal::enable_if<true, Eigen::IndexedView<const Eigen::Map<Eigen::Matrix<double, -1, -1> >, double, double> >::type’ {aka ‘Eigen::IndexedView<const Eigen::Map<Eigen::Matrix<double, -1, -1> >, double, double>’} to ‘Eigen::DenseCoeffsBase<Eigen::Matrix<double, -1, 1>, 1>::Scalar’ {aka ‘double’} in assignment
  180 |    tmp_rho(i) = RHO(snps1(1 , i)-1, snps1(0 , i)-1);
      |                 ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      |                    |

The error at the end is the following:

/home/LINUX-USERNAME/R/x86_64-pc-linux-gnu-library/4.4/RcppEigen/include/Eigen/src/Core/DenseCoeffsBase.h:654:74: warning: ignoring attributes on template argument ‘Eigen::internal::packet_traits<double>::type’ {aka ‘__m128d’} [-Wignored-attributes]
make: *** [/opt/R/4.4.0/lib/R/etc/Makeconf:204: align2.o] Error 1
ERROR: compilation failed for package ‘hyprcoloc’
* removing ‘/tmp/RtmpbzxBR5/Rinst9f04595319c/hyprcoloc’
      -----------------------------------
ERROR: package installation failed
Error: Failed to install 'hyprcoloc' from GitHub:
  ! System command 'R' failed
Execution halted

Here is the result of the sessionInfo() command: image

Any assistance would be appreciated!

maher-95 commented 2 months ago

Hi, I hope you've solved your problem already, but after struggling with the same issue, the solution in the how to of the jrs95 version of hyprcoloc worked for me. In short, forcing installation of an older version of RcppEigen (0.3.3.9.3) worked.

https://github.com/jrs95/hyprcoloc/issues/30

koripainchaud commented 2 months ago

Hi @maher-95,

Thanks for replying! Using the older version of RcppEigen (0.3.3.9.3) worked for me as well.

remotes::install_version('RcppEigen', version = '0.3.3.9.3')

I will close this issue now.