ERROR: dependency 'transformr' is not available for package 'gganimate'

ggplot2
rtools
package-installation

#1

Hello,

I was using the gganimate package and it worked quite well until i updated my packages.

I can't run it anymore because of dependency error : "ERROR: dependency 'transformr' is not available for package 'gganimate'".

It seems that the package does not exist anymore : https://cran.r-project.org/web/packages/available_packages_by_name.html (it is not listed on the CRAN)

Someone has a solution ?

Thanks in advance


#2

You should still be able to install it from the GitHub repo

# install.packages("devtools")
devtools::install_github("thomasp85/transformr")

#3

I tried downloading transformr as you suggested from GitHub in order to run gganimate but apparently, the available Rtools are incompatible?! I made sure to have downloaded the latest version.

See error message:

Downloading GitHub repo thomasp85/gganimate@master
from URL https://api.github.com/repos/thomasp85/gganimate/zipball/master
Installing gganimate
Downloading GitHub repo thomasp85/tweenr@master
from URL https://api.github.com/repos/thomasp85/tweenr/zipball/master
WARNING: Rtools is required to build R packages, but no version of Rtools compatible with R 3.5.1 was found. (Only the following incompatible version(s) of Rtools were found:3.5)

Please download and install the appropriate version of Rtools from http://cran.r-project.org/bin/windows/Rtools/.
Installation failed: Could not find build tools necessary to build tweenr
Downloading GitHub repo thomasp85/transformr@master
from URL https://api.github.com/repos/thomasp85/transformr/zipball/master
WARNING: Rtools is required to build R packages, but no version of Rtools compatible with R 3.5.1 was found. (Only the following incompatible version(s) of Rtools were found:3.5)

Please download and install the appropriate version of Rtools from http://cran.r-project.org/bin/windows/Rtools/.
Installation failed: Could not find build tools necessary to build transformr

#4

I believe the Rtools incompatibility is between R 3.5 and Rtools. I'm not a Windows user, so I don't know much about it, but that's the impression I've gotten from others.


#6

There is some problem with the Rtools as well.

It is a PATH and version problem, that appeared since R 3.5.

Here is the bug fix :

# Set path of Rtools
Sys.setenv(PATH = paste(Sys.getenv("PATH"), "*InstallDirectory*/Rtools/bin/",
                       "*InstallDirectory*/Rtools/mingw_64/bin", sep = ";")) #for 64 bit version
Sys.setenv(BINPREF = "*InstallDirectory*/Rtools/mingw_64/bin")
library(devtools)

#Manually "force" version to be accepted 
assignInNamespace("version_info", c(devtools:::version_info, list("3.5" = list(version_min = "3.3.0", version_max = "99.99.99", path = "bin"))), "devtools")
find_rtools() # is TRUE now

# Now you can install transformr then gganimate
devtools::install_github("thomasp85/transformr")
devtools::install_github("dgrtwo/gganimate")

I hope it works for you.


Rtools not recognized (R3.5.1, Rtools 3.5)
#7

I made an account just to thank you for posting this fix. Cheers!


#8

Thanks, credit is not mine but I don't remember where I took it.


#10

Thanks, @AntoineC, your code plus reinstalling Rtools finally solved the issue!


#11

A post was split to a new topic: Help with "Installation failed: Could not find build tools necessary to build transformr"


#12

Hi I have tried your approach but it didn't resolve the issue for me. Can you please advise is there any other approach. I tried installing the Rtools multiple times and set the path as well.