Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

R 2.14 byte compile - not possible with install.packages?

Tags:

r

It seems that R 2.14 can byte-compile packages using a switch on R CMD INSTALL but I couldn't find such an option in the install.packages documentation. Am I missing something?

like image 342
SFun28 Avatar asked Dec 01 '11 14:12

SFun28


1 Answers

As it says in ?install.packages, you can use the INSTALL_opts= argument to pass additional options to R CMD INSTALL for a source package install. If you're installing a binary package from CRAN, it's likely already byte-compiled.

For example, to install from source and byte-compile manually (make sure you have the necessary tools):

install.packages("xts", type="source", INSTALL_opts="--byte-compile")
like image 109
Joshua Ulrich Avatar answered Nov 15 '22 01:11

Joshua Ulrich