I have two computers and in one of them I can't manage to install the plyr package for R. This is the error I get:
* installing *source* package ‘plyr’ ...
** package ‘plyr’ successfully unpacked and MD5 sums checked
** libs
g++ -I/usr/share/R/include -DNDEBUG -I"/usr/lib/R/site-library/Rcpp/include" -fpic -O2 -pipe -g -c RcppExports.cpp -o RcppExports.o
RcppExports.cpp: En la función ‘SEXPREC* plyr_loop_apply(SEXP, SEXP)’:
RcppExports.cpp:15:9: error: ‘input_parameter’ no es un miembro de ‘Rcpp::traits’
RcppExports.cpp:15:40: error: expected primary-expression before ‘int’
RcppExports.cpp:15:40: error: expected ‘;’ before ‘int’
RcppExports.cpp:16:9: error: ‘input_parameter’ no es un miembro de ‘Rcpp::traits’
RcppExports.cpp:16:49: error: expected primary-expression before ‘>’ token
RcppExports.cpp:16:50: error: ‘::type’ no se ha declarado
RcppExports.cpp:16:57: error: expected ‘;’ before ‘f’
RcppExports.cpp:17:36: error: ‘n’ no se declaró en este ámbito
RcppExports.cpp:17:39: error: ‘f’ no se declaró en este ámbito
RcppExports.cpp: En la función ‘SEXPREC* plyr_split_indices(SEXP, SEXP)’:
RcppExports.cpp:31:9: error: ‘input_parameter’ no es un miembro de ‘Rcpp::traits’
RcppExports.cpp:31:54: error: expected primary-expression before ‘>’ token
RcppExports.cpp:31:55: error: ‘::type’ no se ha declarado
RcppExports.cpp:31:62: error: expected ‘;’ before ‘group’
RcppExports.cpp:32:9: error: ‘input_parameter’ no es un miembro de ‘Rcpp::traits’
RcppExports.cpp:32:40: error: expected primary-expression before ‘int’
RcppExports.cpp:32:40: error: expected ‘;’ before ‘int’
RcppExports.cpp:33:65: error: ‘group’ no se declaró en este ámbito
RcppExports.cpp:33:72: error: ‘n’ no se declaró en este ámbito
make: *** [RcppExports.o] Error 1
ERROR: compilation failed for package ‘plyr’
* removing ‘/home/rgalhama/R/x86_64-pc-linux-gnu-library/2.15/plyr’
Warning in install.packages :
installation of package ‘plyr’ had non-zero exit status
It looks like the package can't be compiled, but I can't figure out why. Before the installation starts, I get this warning message:
Warning in install.packages : dependency ‘Rcpp’ is not available
I have installed rcpp from the system (as sudo apt-get install r-cran-rcpp), since I don't find a way to install it from R:
install.packages("Rcpp", repos='http://cran.us.r-project.org') Installing package(s) into ‘/home/rgalhama/R/x86_64-pc-linux-gnu-library/2.15’ (as ‘lib’ is unspecified) Warning in install.packages : package ‘Rcpp’ is not available (for R version 2.15.2)
But still I don't know if these errors are related.
Any ideas?
Thanks!