Thanks for clarification and here is the console:
> githubinstall('winference')
Suggestion:
- pierrejacob/winference R package to perform statistical inference in generative models using the Wasserstein distance
Do you want to install the package (Y/n)? y
Downloading GitHub repo pierrejacob/winference@master
These packages have more recent versions available.
It is recommended to update all of them.
Which would you like to update?
1: All
2: CRAN packages only
3: None
4: Rcpp (1.0.8 -> 1.0.9) [CRAN]
5: magrittr (2.0.2 -> 2.0.3) [CRAN]
6: stringi (1.7.6 -> 1.7.8) [CRAN]
Enter one or more numbers, or an empty line to skip updates: 1
Rcpp (1.0.8 -> 1.0.9) [CRAN]
magrittr (2.0.2 -> 2.0.3) [CRAN]
stringi (1.7.6 -> 1.7.8) [CRAN]
Installing 3 packages: Rcpp, magrittr, stringi
Warning: 正在使用‘Rcpp’这个程序包,因此不会被安装
有二进制版本的,但源代码版本是后来的:
binary source needs_compilation
stringi 1.7.6 1.7.8 TRUE
trying URL 'https://cran.rstudio.com/bin/windows/contrib/4.1/magrittr_2.0.3.zip'
Content type 'application/zip' length 238598 bytes (233 KB)
downloaded 233 KB
package ‘magrittr’ successfully unpacked and MD5 sums checked
Warning: cannot remove prior installation of package ‘magrittr’
Warning: restored ‘magrittr’
The downloaded binary packages are in
C:\Users\zhiqi\AppData\Local\Temp\Rtmpqwr4Zw\downloaded_packages
安装源码包‘stringi’
trying URL 'https://cran.rstudio.com/src/contrib/stringi_1.7.8.tar.gz'
Content type 'application/x-gzip' length 8032287 bytes (7.7 MB)
downloaded 7.7 MB
* installing *source* package 'stringi' ...
** package 'stringi' successfully unpacked and MD5 sums checked
ERROR: cannot remove earlier installation, is it in use?
* removing 'D:/downloads/R-4.1.3/library/stringi'
* restoring previous 'D:/downloads/R-4.1.3/library/stringi'
Warning in file.copy(lp, dirname(pkgdir), recursive = TRUE, copy.date = TRUE) :
拷贝D:\downloads\R-4.1.3\library\00LOCK-stringi\stringi\libs\icudt69l.dat到D:\downloads\R-4.1.3\library\stringi\libs\icudt69l.dat时出了问题:Invalid argument
Warning in file.copy(lp, dirname(pkgdir), recursive = TRUE, copy.date = TRUE) :
拷贝D:\downloads\R-4.1.3\library\00LOCK-stringi\stringi\libs\x64\stringi.dll到D:\downloads\R-4.1.3\library\stringi\libs\x64\stringi.dll时出了问题:Permission denied
The downloaded source packages are in
‘C:\Users\zhiqi\AppData\Local\Temp\Rtmpqwr4Zw\downloaded_packages’
v checking for file 'C:\Users\zhiqi\AppData\Local\Temp\Rtmpqwr4Zw\remotes1618618d7c19\pierrejacob-winference-bba0e89/DESCRIPTION' ...
- preparing 'winference': (2.4s)
v checking DESCRIPTION meta-information ...
- cleaning src
- checking for LF line-endings in source and make files and shell scripts
- checking for empty or unneeded directories
Omitted 'LazyData' from DESCRIPTION
- building 'winference_0.1.2.tar.gz'
* installing *source* package 'winference' ...
** using staged installation
** libs
*** arch - i386
/mingw32/bin/g++ -std=gnu++14 -I"D:/DOWNLO~1/R-41~1.3/include" -DNDEBUG -I'D:/downloads/R-4.1.3/library/Rcpp/include' -I'D:/downloads/R-4.1.3/library/RcppEigen/include' -I'D:/downloads/R-4.1.3/library/BH/include' -O2 -Wall -mfpmath=sse -msse2 -mstackrealign -c HilbertCode.cpp -o HilbertCode.o
HilbertCode.cpp:2:10: fatal error: CGAL/Exact_predicates_inexact_constructions_kernel.h: No such file or directory
#include <CGAL/Exact_predicates_inexact_constructions_kernel.h>
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [D:/DOWNLO~1/R-41~1.3/etc/i386/Makeconf:245: HilbertCode.o] Error 1
ERROR: compilation failed for package 'winference'
* removing 'D:/downloads/R-4.1.3/library/winference'
Warning messages:
1: In file.copy(savedcopy, lib, recursive = TRUE) :
problem copying D:\downloads\R-4.1.3\library\00LOCK\magrittr\libs\x64\magrittr.dll to D:\downloads\R-4.1.3\library\magrittr\libs\x64\magrittr.dll: Permission denied
2: In i.p(...) :
installation of package ‘stringi’ had non-zero exit status
3: In i.p(...) :
installation of package ‘C:/Users/zhiqi/AppData/Local/Temp/Rtmpqwr4Zw/file161824352e99/winference_0.1.2.tar.gz’ had non-zero exit status
It seems like the missing of CGAL is sensible.
But how can I download CGAL and link it to R? Or I just need to download the CGAL and it would work?