Installation of archived package "prob" not working in R - r

I'm running R 3.4.2 and R Studio 1.0.153. I want to install the prob package in R. The prob package in an archived file. It is located here. I am trying to install the prob_1.0-0.tar.gz package. I have no problem downloading and opening the package archive file. The code is below, it seems I need to install the fAsianOptions package.
ERROR: dependency 'fAsianOptions' is not available for package 'prob'
* removing 'C:/Users/blake_000/Documents/R/win-library/3.4/prob' Warning in install.packages : running command
'"C:/PROGRA~1/R/R-34~1.2/bin/x64/R" CMD INSTALL -l
"C:\Users\blake_000\Documents\R\win-library\3.4"
"C:/Users/BLAKE_~1/GOOGLE~1/Life/CSUEB/FALL20~1/6204-P~1/RCODE~1/prob_1.0-0.tar.gz"'
had status 1 Warning in install.packages : installation of package
‘C:/Users/BLAKE_~1/GOOGLE~1/Life/CSUEB/FALL20~1/6204-P~1/RCODE~1/prob_1.0-0.tar.gz’
had non-zero exit status
Unfortunately, the fAsianOptions package is also archived. It is located here and I downloaded version fAsianOptions_3010.79.tar.gz. There were a number of dependencies but I installed the required packages (timeDate, timeSeries, etc.)
However, the fAsianOptions package is not installing. The error code reads as follows:
install.packages("C:/Users/blake_000/Google Drive/Life/CSUEB/Fall
2017/6204- Probability/R Code/fAsianOptions_3010.79.tar.gz", repos =
NULL, type = "source") Installing package into
‘C:/Users/blake_000/Documents/R/win-library/3.4’ (as ‘lib’ is
unspecified)
* installing source package 'fAsianOptions' ...
** package 'fAsianOptions' successfully unpacked and MD5 sums checked
** libs
*** arch - i386 Warning: running command 'make -f "Makevars" -f "C:/PROGRA~1/R/R-34~1.2/etc/i386/Makeconf" -f
"C:/PROGRA~1/R/R-34~1.2/share/make/winshlib.mk"
SHLIB="fAsianOptions.dll" SHLIB_LIBADD='$(FLIBS)'
OBJECTS="EBMAsianOptions.o GammaFunctions.o
HypergeometricFunctions.o"' had status 127 ERROR: compilation failed
for package 'fAsianOptions'
* removing 'C:/Users/blake_000/Documents/R/win-library/3.4/fAsianOptions' Warning
in install.packages : running command
'"C:/PROGRA~1/R/R-34~1.2/bin/x64/R" CMD INSTALL -l
"C:\Users\blake_000\Documents\R\win-library\3.4"
"C:/Users/BLAKE_~1/GOOGLE~1/Life/CSUEB/FALL20~1/6204-P~1/RCODE~1/fAsianOptions_3010.79.tar.gz"'
had status 1 Warning in install.packages : installation of package
‘C:/Users/BLAKE_~1/GOOGLE~1/Life/CSUEB/FALL20~1/6204-P~1/RCODE~1/fAsianOptions_3010.79.tar.gz’
had non-zero exit status
I'm hoping that someone can help me to install the fAsianOptions dependency so I can install the prob package. Or, if there's an easier way, please let me know!

I had the same problem. I solved it by installing lower version of R -2.9. prob is available in repository for this version.

Related

Unable to install magrittr

Got a new company laptop and tried to install tidyr or installr, but it always fails because of magrittr.
If I want to install this package directly I'm getting the following error code:
* installing *source* package 'magrittr' ...
** package 'magrittr' successfully unpacked and MD5 sums checked
** libs
*** arch - i386
Warning: running command 'make -f "C:/PROGRA~1/R/R-33~1.1/etc/i386/Makeconf" -f "C:/PROGRA~1/R/R-33~1.1/share/make/winshlib.mk" SHLIB="magrittr.dll" OBJECTS="pipe.o utils.o"' had status 127
ERROR: compilation failed for package 'magrittr'
* removing 'C:/Users/xxxx/Documents/R/win-library/3.3/magrittr'
Warning in install.packages :
running command '"C:/PROGRA~1/R/R-33~1.1/bin/x64/R" CMD INSTALL -l "C:\Users\xxxx\Documents\R\win-library\3.3" C:\Users\xxxx\AppData\Local\Temp\1\RtmpMHlNI9/downloaded_packages/magrittr_2.0.1.tar.gz' had status 1
Warning in install.packages :
installation of package ‘magrittr’ had non-zero exit status
I don't have admin privileges on this computer and could imagine that this could be the source of the problem, but I'm not sure.
What I tried:
Changed folder for libraries
Reinstalled all libraries
Tried different cron repos
Tried to install it on this way: install.packages("magrittr", update.packages(checkBuilt = TRUE))
Always the same error.
Is there any other way to install it?
Installing an archived version from source will work.
install.packages("cran.r-project.org/src/contrib/Archive/magrittr/…", repos = NULL, type="source")
You can utilize conda to install it:
conda install -c r r-magrittr
Reference:
https://anaconda.org/r/r-magrittr

install daewr package in R 4.0

hi i am trying to install package for experiment designs like this
install.packages("daewr", dependencies = T)
but it returns the following
configure: error: GNU MP not found, or not 4.1.4 or up, see http://gmplib.org
ERROR: configuration failed for package ‘gmp’
* removing ‘/home/yeferson/R/x86_64-pc-linux-gnu-library/4.0/gmp’
Warning in install.packages :
installation of package ‘gmp’ had non-zero exit status
ERROR: dependency ‘gmp’ is not available for package ‘partitions’
* removing ‘/home/yeferson/R/x86_64-pc-linux-gnu-library/4.0/partitions’
Warning in install.packages :
installation of package ‘partitions’ had non-zero exit status
ERROR: dependency ‘partitions’ is not available for package ‘DoE.base’
* removing ‘/home/yeferson/R/x86_64-pc-linux-gnu-library/4.0/DoE.base’
Warning in install.packages :
installation of package ‘DoE.base’ had non-zero exit status
ERROR: dependency ‘DoE.base’ is not available for package ‘FrF2’
* removing ‘/home/yeferson/R/x86_64-pc-linux-gnu-library/4.0/FrF2’
Warning in install.packages :
installation of package ‘FrF2’ had non-zero exit status
ERROR: dependency ‘FrF2’ is not available for package ‘daewr’
* removing ‘/home/yeferson/R/x86_64-pc-linux-gnu-library/4.0/daewr’
Warning in install.packages :
installation of package ‘daewr’ had non-zero exit status
The downloaded source packages are in
‘/tmp/RtmpB1bSe0/downloaded_packages’
so i decided to download the file from https://cran.r-project.org/web/packages/daewr/index.html
after trying to install it returns me
also installing the dependencies ‘gmp’, ‘partitions’, ‘DoE.base’, ‘FrF2.catlg128’
I try to install the first one but it asks for a Bessel package and it still gives me problems
I solved it by installing dependency one by one, many answer you install the dependencies but they do not say how I will explain them for the new ones in linux and in R to install the daerw package with the aforementioned problems, install the following in the linux console
sudo apt-get install libgsl-dev
with that install libraries now I can open R and install
install.packages('gsl')
then I opened the linux console again and installed
sudo apt-get install libgmp-dev
I go back to R and install
install.packages("gmp", dependencies = T)
now I can install the package without problems
install.packages("daewr", dependencies = T)
library(daewr)
I hope that any comment is welcome.

how to install in R CvM2SL2Test package (Cramer-von Mises Two Sample Test)

I am trying to install the following package CvM2SL2Test in R, but i do not manage to do it. I have tried from CRAN, but it seems that it is not available anymore. In the end, i have tried locally (downloading the package from http://ftp.naist.jp/pub/CRAN/src/contrib/Archive/CvM2SL2Test/) but i am obtaining the following error:
Installing package into ‘C:/Users/David/Documents/R/win-library/3.4’
(as ‘lib’ is unspecified)
* installing *source* package 'CvM2SL2Test' ...
** package 'CvM2SL2Test' successfully unpacked and MD5 sums checked
** libs
*** arch - i386
Warning: comando ejecutado 'make -f "C:/PROGRA~1/R/R-34~1.4/etc/i386/Makeconf" -f "C:/PROGRA~1/R/R-34~1.4/share/make/winshlib.mk" SHLIB_LDFLAGS='$(SHLIB_CXXLDFLAGS)' SHLIB_LD='$(SHLIB_CXXLD)' SHLIB="CvM2SL2Test.dll" OBJECTS="CvM2SL2Test.o XCVM.o XCVMTailProb.o XCVMTailProb_EQ.o XCVMTailProb_NE1.o XCVMTailProb_NE2.o XCvMTest.o XFreqFunct.o"' tiene estatus 127
ERROR: compilation failed for package 'CvM2SL2Test'
* removing 'C:/Users/David/Documents/R/win-library/3.4/CvM2SL2Test'
In R CMD INSTALL
Warning in install.packages :
running command '"C:/PROGRA~1/R/R-34~1.4/bin/x64/R" CMD INSTALL -l "C:\Users\David\Documents\R\win-library\3.4" "C:/Users/David/Downloads/CvM2SL2Test_2.0-1.tar.gz"' had status 1
Warning in install.packages :
installation of package ‘C:/Users/David/Downloads/CvM2SL2Test_2.0-1.tar.gz’ had non-zero exit status
Given that i am using windows 10, i have extracted the folder, and used the extention .zip. Then i have been able to obtain the following result:
Installing package into ‘C:/Users/David/Documents/R/win-library/3.4’
(as ‘lib’ is unspecified)
package ‘CvM2SL2Test’ successfully unpacked and MD5 sums checked
However, when using like library(‘CvM2SL2Test’), I see the following:
library('CvM2SL2Test')
Error in library("CvM2SL2Test") :
‘CvM2SL2Test’ is not a valid installed package
I do not know how to install propery this package in windows 10 in order to use it properly, how can i do it?
Thanks in advance.
You appear to have a problem running the make command. This probably indicates that you don't have the R Tools collection (see https://cloud.r-project.org/bin/windows/Rtools/) installed, or it is not installed properly.

Error when installing gpclib

R version 3.2.1
I downloaded gpclib_1.5-5.tar.gz from http://cran.r-project.org/web/packages/gpclib/index.html and attempted to install the package with
install.packages("D:/GIS/gpclib_1.5-5.tar.gz", repos = NULL, type = "source")
I get the error
* installing *source* package 'gpclib' ...
** package 'gpclib' successfully unpacked and MD5 sums checked
** libs
*** arch - i386
Warning: running command 'make -f "D:/R/R-3.2.1/etc/i386/Makeconf" -f "D:/R/R-3.2.1/share/make/winshlib.mk" SHLIB="gpclib.dll" OBJECTS="Rgpc.o gpc.o"' had status 127
ERROR: compilation failed for package 'gpclib'
* removing 'D:/R/R-3.2.1/library/gpclib'
Warning in install.packages :
running command '"D:/R/R-3.2.1/bin/x64/R" CMD INSTALL -l "D:\R\R-3.2.1\library" "D:/GIS/gpclib_1.5-5.tar.gz"' had status 1
Warning in install.packages :
installation of package ‘D:/GIS/gpclib_1.5-5.tar.gz’ had non-zero exit status
How do I troubleshoot this?
Extra Information
I am ultimately trying to create heat maps, and am following this tutorial
http://spatialanalysis.co.uk/wp-content/uploads/2013/04/james_cheshire_ggplot_intro_blog.pdf
You'll need to install Rtools to install the R compiler libraries:
http://cran.r-project.org/bin/windows/Rtools/
Otherwise, R will have issues compiling from source code.

R Packages Installation Error on Ubuntu

I am trying to install the R package "colorspace" in Ubuntu Linux from local repository as follows:
install.packages("/home/colorspace_1.2-4.tar.gz", repos = NULL, type="source")
This throws the following error:
Installing package into '/home/vertica/R/x86_64-unknown-linux-gnu-library/3.0'
(as 'lib' is unspecified)
* installing *source* package 'colorspace' ...
** package 'colorspace' successfully unpacked and MD5 sums checked
** libs
sh: make: command not found
ERROR: compilation failed for package 'colorspace'
* removing '/home/vertica/R/x86_64-unknown-linux-gnu-library/3.0/colorspace'
Warning message:
In install.packages("/home/colorspace_1.2-4.tar.gz", :
installation of package '/home/colorspace_1.2-4.tar.gz' had non-zero exit
status
Could someone help me with this issue?
Thank you.
Ravi
Its saying it can't find "make", which makes me think you don't have all the compilers and so on that you need to build packages from source.
Install the "build-essential" package, something like:
sudo apt-get install build-essential
from your command line (not from R!)

Resources