Installing “choroplethr” in Ubuntu
I am trying to install "choroplethr."
I have read the following related-looking errors:
- https://askubuntu.com/questions/1057100/error-libudunits2-a-not-found-when-installing-ggraph-additional-error-objec
- Install udunits2 package for R3.3
Their recommendation is to install something I have already installed. I have libudunits2 installed in a standard location, with:
$ sudo apt-get install libudunits2-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libudunits2-dev is already the newest version (2.2.26-1).
I can see headers:
$ ll /usr/include/ | grep unit
-rw-r--r-- 1 root root 39998 Jan 5 2018 udunits2.h
-rw-r--r-- 1 root root 5195 Jan 5 2018 udunits.h
However, on installation, I get this error:
$ R
R version 3.5.1 (2018-07-02) -- "Feather Spray"
> install.package("choroplethr", dep=T)
...
configure: error: in `/tmp/RtmpWC06JV/R.INSTALL7cbb4928db67/units':
configure: error:
--------------------------------------------------------------------------------
Configuration failed because libudunits2.so was not found. Try installing:
* deb: libudunits2-dev (Debian, Ubuntu, ...)
* rpm: udunits2-devel (Fedora, EPEL, ...)
* brew: udunits (OSX)
If udunits2 is already installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
if the library was not found, and/or:
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values.
You can alternatively set UDUNITS2_INCLUDE and UDUNITS2_LIBS manually.
--------------------------------------------------------------------------------
I've done these settings, but
install.packages("udunits2", configure.args = '--with-udunits2-include=/usr/include/udunits2')
-----Error: libudunits2.a not found-----
If the udunits2 library is installed in a non-standard location,
use --configure-args='--with-udunits2-lib=/usr/local/lib' for example,
or --configure-args='--with-udunits2-include=/usr/include/udunits2'
replacing paths with appropriate values for your installation.
You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIB
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
What am I missing? Is this package OSX only?
r ggplot2 tidyverse rgdal choroplethr
add a comment |
I am trying to install "choroplethr."
I have read the following related-looking errors:
- https://askubuntu.com/questions/1057100/error-libudunits2-a-not-found-when-installing-ggraph-additional-error-objec
- Install udunits2 package for R3.3
Their recommendation is to install something I have already installed. I have libudunits2 installed in a standard location, with:
$ sudo apt-get install libudunits2-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libudunits2-dev is already the newest version (2.2.26-1).
I can see headers:
$ ll /usr/include/ | grep unit
-rw-r--r-- 1 root root 39998 Jan 5 2018 udunits2.h
-rw-r--r-- 1 root root 5195 Jan 5 2018 udunits.h
However, on installation, I get this error:
$ R
R version 3.5.1 (2018-07-02) -- "Feather Spray"
> install.package("choroplethr", dep=T)
...
configure: error: in `/tmp/RtmpWC06JV/R.INSTALL7cbb4928db67/units':
configure: error:
--------------------------------------------------------------------------------
Configuration failed because libudunits2.so was not found. Try installing:
* deb: libudunits2-dev (Debian, Ubuntu, ...)
* rpm: udunits2-devel (Fedora, EPEL, ...)
* brew: udunits (OSX)
If udunits2 is already installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
if the library was not found, and/or:
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values.
You can alternatively set UDUNITS2_INCLUDE and UDUNITS2_LIBS manually.
--------------------------------------------------------------------------------
I've done these settings, but
install.packages("udunits2", configure.args = '--with-udunits2-include=/usr/include/udunits2')
-----Error: libudunits2.a not found-----
If the udunits2 library is installed in a non-standard location,
use --configure-args='--with-udunits2-lib=/usr/local/lib' for example,
or --configure-args='--with-udunits2-include=/usr/include/udunits2'
replacing paths with appropriate values for your installation.
You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIB
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
What am I missing? Is this package OSX only?
r ggplot2 tidyverse rgdal choroplethr
Which Ubuntu version do you use?
– Ralf Stubner
Nov 23 '18 at 5:59
Ubuntu version 18.04
– Mittenchops
Nov 23 '18 at 6:21
add a comment |
I am trying to install "choroplethr."
I have read the following related-looking errors:
- https://askubuntu.com/questions/1057100/error-libudunits2-a-not-found-when-installing-ggraph-additional-error-objec
- Install udunits2 package for R3.3
Their recommendation is to install something I have already installed. I have libudunits2 installed in a standard location, with:
$ sudo apt-get install libudunits2-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libudunits2-dev is already the newest version (2.2.26-1).
I can see headers:
$ ll /usr/include/ | grep unit
-rw-r--r-- 1 root root 39998 Jan 5 2018 udunits2.h
-rw-r--r-- 1 root root 5195 Jan 5 2018 udunits.h
However, on installation, I get this error:
$ R
R version 3.5.1 (2018-07-02) -- "Feather Spray"
> install.package("choroplethr", dep=T)
...
configure: error: in `/tmp/RtmpWC06JV/R.INSTALL7cbb4928db67/units':
configure: error:
--------------------------------------------------------------------------------
Configuration failed because libudunits2.so was not found. Try installing:
* deb: libudunits2-dev (Debian, Ubuntu, ...)
* rpm: udunits2-devel (Fedora, EPEL, ...)
* brew: udunits (OSX)
If udunits2 is already installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
if the library was not found, and/or:
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values.
You can alternatively set UDUNITS2_INCLUDE and UDUNITS2_LIBS manually.
--------------------------------------------------------------------------------
I've done these settings, but
install.packages("udunits2", configure.args = '--with-udunits2-include=/usr/include/udunits2')
-----Error: libudunits2.a not found-----
If the udunits2 library is installed in a non-standard location,
use --configure-args='--with-udunits2-lib=/usr/local/lib' for example,
or --configure-args='--with-udunits2-include=/usr/include/udunits2'
replacing paths with appropriate values for your installation.
You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIB
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
What am I missing? Is this package OSX only?
r ggplot2 tidyverse rgdal choroplethr
I am trying to install "choroplethr."
I have read the following related-looking errors:
- https://askubuntu.com/questions/1057100/error-libudunits2-a-not-found-when-installing-ggraph-additional-error-objec
- Install udunits2 package for R3.3
Their recommendation is to install something I have already installed. I have libudunits2 installed in a standard location, with:
$ sudo apt-get install libudunits2-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libudunits2-dev is already the newest version (2.2.26-1).
I can see headers:
$ ll /usr/include/ | grep unit
-rw-r--r-- 1 root root 39998 Jan 5 2018 udunits2.h
-rw-r--r-- 1 root root 5195 Jan 5 2018 udunits.h
However, on installation, I get this error:
$ R
R version 3.5.1 (2018-07-02) -- "Feather Spray"
> install.package("choroplethr", dep=T)
...
configure: error: in `/tmp/RtmpWC06JV/R.INSTALL7cbb4928db67/units':
configure: error:
--------------------------------------------------------------------------------
Configuration failed because libudunits2.so was not found. Try installing:
* deb: libudunits2-dev (Debian, Ubuntu, ...)
* rpm: udunits2-devel (Fedora, EPEL, ...)
* brew: udunits (OSX)
If udunits2 is already installed in a non-standard location, use:
--configure-args='--with-udunits2-lib=/usr/local/lib'
if the library was not found, and/or:
--configure-args='--with-udunits2-include=/usr/include/udunits2'
if the header was not found, replacing paths with appropriate values.
You can alternatively set UDUNITS2_INCLUDE and UDUNITS2_LIBS manually.
--------------------------------------------------------------------------------
I've done these settings, but
install.packages("udunits2", configure.args = '--with-udunits2-include=/usr/include/udunits2')
-----Error: libudunits2.a not found-----
If the udunits2 library is installed in a non-standard location,
use --configure-args='--with-udunits2-lib=/usr/local/lib' for example,
or --configure-args='--with-udunits2-include=/usr/include/udunits2'
replacing paths with appropriate values for your installation.
You can alternatively use the UDUNITS2_INCLUDE and UDUNITS2_LIB
environment variables.
If udunits2 is not installed, please install it.
It is required for this package.
What am I missing? Is this package OSX only?
r ggplot2 tidyverse rgdal choroplethr
r ggplot2 tidyverse rgdal choroplethr
asked Nov 23 '18 at 5:28
MittenchopsMittenchops
6,5612268140
6,5612268140
Which Ubuntu version do you use?
– Ralf Stubner
Nov 23 '18 at 5:59
Ubuntu version 18.04
– Mittenchops
Nov 23 '18 at 6:21
add a comment |
Which Ubuntu version do you use?
– Ralf Stubner
Nov 23 '18 at 5:59
Ubuntu version 18.04
– Mittenchops
Nov 23 '18 at 6:21
Which Ubuntu version do you use?
– Ralf Stubner
Nov 23 '18 at 5:59
Which Ubuntu version do you use?
– Ralf Stubner
Nov 23 '18 at 5:59
Ubuntu version 18.04
– Mittenchops
Nov 23 '18 at 6:21
Ubuntu version 18.04
– Mittenchops
Nov 23 '18 at 6:21
add a comment |
1 Answer
1
active
oldest
votes
For Ubuntu with R 3.5 you can use the c2d4u3.5 PPA made available by the same persons that bring you R Ubuntu packages on CRAN, c.f. https://cran.r-project.org/bin/linux/ubuntu/README.html and http://dirk.eddelbuettel.com/blog/2017/12/22/:
sudo add-apt-repository ppa:marutter/c2d4u3.5
sudo apt-get update
After that you can install binary packages for most CRAN packages:
sudo apt-get install r-cran-choroplethr
This should work for all packages that are mentioned in CRAN task views.
Besides this, I tried to reproduce your installation problems using docker:
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
&& apt-get install --yes --no-install-recommends gnupg ca-certificates
&& apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
&& echo "deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/" >> /etc/apt/sources.list
&& apt-get update
&& apt-get install --yes --no-install-recommends r-base-dev libudunits2-dev
&& Rscript -e 'install.packages(c("units", "udunits2"))'
However, the image was build without problems.
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53441069%2finstalling-choroplethr-in-ubuntu%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
For Ubuntu with R 3.5 you can use the c2d4u3.5 PPA made available by the same persons that bring you R Ubuntu packages on CRAN, c.f. https://cran.r-project.org/bin/linux/ubuntu/README.html and http://dirk.eddelbuettel.com/blog/2017/12/22/:
sudo add-apt-repository ppa:marutter/c2d4u3.5
sudo apt-get update
After that you can install binary packages for most CRAN packages:
sudo apt-get install r-cran-choroplethr
This should work for all packages that are mentioned in CRAN task views.
Besides this, I tried to reproduce your installation problems using docker:
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
&& apt-get install --yes --no-install-recommends gnupg ca-certificates
&& apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
&& echo "deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/" >> /etc/apt/sources.list
&& apt-get update
&& apt-get install --yes --no-install-recommends r-base-dev libudunits2-dev
&& Rscript -e 'install.packages(c("units", "udunits2"))'
However, the image was build without problems.
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
add a comment |
For Ubuntu with R 3.5 you can use the c2d4u3.5 PPA made available by the same persons that bring you R Ubuntu packages on CRAN, c.f. https://cran.r-project.org/bin/linux/ubuntu/README.html and http://dirk.eddelbuettel.com/blog/2017/12/22/:
sudo add-apt-repository ppa:marutter/c2d4u3.5
sudo apt-get update
After that you can install binary packages for most CRAN packages:
sudo apt-get install r-cran-choroplethr
This should work for all packages that are mentioned in CRAN task views.
Besides this, I tried to reproduce your installation problems using docker:
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
&& apt-get install --yes --no-install-recommends gnupg ca-certificates
&& apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
&& echo "deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/" >> /etc/apt/sources.list
&& apt-get update
&& apt-get install --yes --no-install-recommends r-base-dev libudunits2-dev
&& Rscript -e 'install.packages(c("units", "udunits2"))'
However, the image was build without problems.
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
add a comment |
For Ubuntu with R 3.5 you can use the c2d4u3.5 PPA made available by the same persons that bring you R Ubuntu packages on CRAN, c.f. https://cran.r-project.org/bin/linux/ubuntu/README.html and http://dirk.eddelbuettel.com/blog/2017/12/22/:
sudo add-apt-repository ppa:marutter/c2d4u3.5
sudo apt-get update
After that you can install binary packages for most CRAN packages:
sudo apt-get install r-cran-choroplethr
This should work for all packages that are mentioned in CRAN task views.
Besides this, I tried to reproduce your installation problems using docker:
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
&& apt-get install --yes --no-install-recommends gnupg ca-certificates
&& apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
&& echo "deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/" >> /etc/apt/sources.list
&& apt-get update
&& apt-get install --yes --no-install-recommends r-base-dev libudunits2-dev
&& Rscript -e 'install.packages(c("units", "udunits2"))'
However, the image was build without problems.
For Ubuntu with R 3.5 you can use the c2d4u3.5 PPA made available by the same persons that bring you R Ubuntu packages on CRAN, c.f. https://cran.r-project.org/bin/linux/ubuntu/README.html and http://dirk.eddelbuettel.com/blog/2017/12/22/:
sudo add-apt-repository ppa:marutter/c2d4u3.5
sudo apt-get update
After that you can install binary packages for most CRAN packages:
sudo apt-get install r-cran-choroplethr
This should work for all packages that are mentioned in CRAN task views.
Besides this, I tried to reproduce your installation problems using docker:
FROM ubuntu:18.04
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get update
&& apt-get install --yes --no-install-recommends gnupg ca-certificates
&& apt-key adv --keyserver keyserver.ubuntu.com --recv-keys E298A3A825C0D65DFD57CBB651716619E084DAB9
&& echo "deb https://cloud.r-project.org/bin/linux/ubuntu bionic-cran35/" >> /etc/apt/sources.list
&& apt-get update
&& apt-get install --yes --no-install-recommends r-base-dev libudunits2-dev
&& Rscript -e 'install.packages(c("units", "udunits2"))'
However, the image was build without problems.
edited Nov 23 '18 at 16:26
answered Nov 23 '18 at 7:17
Ralf StubnerRalf Stubner
15.3k21840
15.3k21840
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
add a comment |
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
Thanks, Ralf. Is there an installation solution that uses the conventional R install interface? I’m hesitant to authorize an extra repo. What’s happening here that requires this third party ppa?
– Mittenchops
Nov 23 '18 at 15:35
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
@Mittenchops Normal installation should work (see the docker file in my updated answer). It is just more convenient to use this PPA, which from my point ov view is trustworthy.
– Ralf Stubner
Nov 23 '18 at 16:27
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53441069%2finstalling-choroplethr-in-ubuntu%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Which Ubuntu version do you use?
– Ralf Stubner
Nov 23 '18 at 5:59
Ubuntu version 18.04
– Mittenchops
Nov 23 '18 at 6:21