Coming soon: We’re working on a brand new, revamped Community experience. Want to receive updates? Sign up now!

0 votes
Hi, I have been trying to do case 2 of the training, but when I try to install ggmap package in my virtual machine I receive a fatal error telling me that jpeglib.h is not found. I read on the internet that this file should be preinstalled or can be installed using apt-get, but every time I try to install it, it appears to me that apt-get is not found. do you have any idea how can I solve this?

1 Answer

+1 vote


The "ggmap" R package depends on the "jpeg" and "png" R package. Both these R packages depend on C libraries. To compile the R packages, you need to have the "development headers" for these C libraries ("libpng" and "libjpeg").

The development headers are contained in system packages. On Debian/Ubuntu system, the command to install system packages is "apt-get" but on CentOS/RedHat system, the command to install system packages is "yum"

So you need to run, as root (because it's a system package):

yum install libpng-devel libjpeg-turbo-devel

And then you can retry the install.packages("ggmap")

1,337 questions
1,364 answers
11,916 users

©Dataiku 2012-2018 - Privacy Policy