Could not install dplyr

Hi, I'm having problem to install the dplyr. I tried to install the tidyverse and it said it could not install the dplyr. Then I tried to install the dplyr and this error appears:

install.packages("dplyr")
Installing package into ‘C:/Users/plaur/Documents/R/win-library/3.6’
(as ‘lib’ is unspecified)

There is a binary version available but the source version is later:
binary source needs_compilation
dplyr 0.8.4 0.8.5 TRUE

installing the source package ‘dplyr’

trying URL 'https://cran.rstudio.com/src/contrib/dplyr_0.8.5.tar.gz'
Content type 'application/x-gzip' length 1378766 bytes (1.3 MB)
downloaded 1.3 MB

  • installing source package 'dplyr' ...
    ** package 'dplyr' successfully unpacked and MD5 sums checked
    ** using staged installation
    ** libs
    C:/Program Files (x86)/Rtools/mingw_64/bin/g++ -std=gnu++11 -I"C:/PROGRA~1/R/R-36~1.3/include" -DNDEBUG -I../inst/include -DRCPP_DEFAULT_INCLUDE_CALL=false -DCOMPILING_DPLYR -DRCPP_USING_UTF8_ERROR_STRING -DRCPP_USE_UNWIND_PROTECT -DBOOST_NO_AUTO_PTR -I"C:/Users/plaur/Documents/R/win-library/3.6/BH/include" -I"C:/Users/plaur/Documents/R/win-library/3.6/plogr/include" -I"C:/Users/plaur/Documents/R/win-library/3.6/Rcpp/include" -O2 -Wall -mtune=core2 -c RcppExports.cpp -o RcppExports.o
    sh: -c: line 0: syntax error near unexpected token (' sh: -c: line 0: C:/Program Files (x86)/Rtools/mingw_64/bin/g++ -std=gnu++11 -I"C:/PROGRA~1/R/R-36~1.3/include" -DNDEBUG -I../inst/include -DRCPP_DEFAULT_INCLUDE_CALL=false -DCOMPILING_DPLYR -DRCPP_USING_UTF8_ERROR_STRING -DRCPP_USE_UNWIND_PROTECT -DBOOST_NO_AUTO_PTR -I"C:/Users/plaur/Documents/R/win-library/3.6/BH/include" -I"C:/Users/plaur/Documents/R/win-library/3.6/plogr/include" -I"C:/Users/plaur/Documents/R/win-library/3.6/Rcpp/include" -O2 -Wall -mtune=core2 -c RcppExports.cpp -o RcppExports.o'
    make: *** [C:/PROGRA~1/R/R-36~1.3/etc/x64/Makeconf:215: RcppExports.o] Error 1
    ERROR: compilation failed for package 'dplyr'
  • removing 'C:/Users/plaur/Documents/R/win-library/3.6/dplyr'
    Warning in install.packages :
    installation of package ‘dplyr’ had non-zero exit status

The downloaded source packages are in
‘C:\Users\plaur\AppData\Local\Temp\RtmpAlm8h6\downloaded_packages’

Could anyone help me out? Thanks!

It looks like dplyr isn't compiling properly on your machine.

You could try installing the 0.8.4 binary with install.packages("dplyr", type = "binary").

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.