安装rgdal-回溯rgdal版本与更新gdal版本,以及如何? [英] Installing rgdal - backdate rgdal version versus update gdal version, and how?

查看:107
本文介绍了安装rgdal-回溯rgdal版本与更新gdal版本,以及如何?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

两部分问题:

1)就像问这个问题的人一样( rgdal不会安装在AWS RStudio AMI 上),我在在Ubuntu 16.04上运行的R上安装rgdal软件包时遇到问题.该软件包需要GDAL 1.11.4或更高版本,而Synaptic软件包管理器仅提供GDAL 1.11.3.

1) Like the person who asked this question (rgdal won't install on AWS RStudio AMI), I'm running into problems installing the rgdal package on R running on Ubuntu 16.04. The package wants GDAL 1.11.4 or later, and Synaptic Package manager is only offering GDAL 1.11.3.

以上问题提供的解决方案是从存档中安装旧版本的rgdal.另一方面,对此较旧问题的答案(

The solution offered on the above question is to install an older version of rgdal from the archive. On the other hand, the answer given to this older question (Trouble getting latest version of GDAL on ubuntu running R) is to install a more recent version of GDAL from ubuntu-unstable.

这两种方法都行吗?

2)每种方法(或者如果两种方法都不起作用,则该方法有效)需要执行哪些步骤?

2) What are the steps required for each approach (or the approach that works if they don't both work)?

推荐答案

最终对我有用的是尝试安装与<代码> gdal 1.11.3 .

What finally worked for me was trying to install an earlier version (v1.2-20) of rgdal that was compatible with gdal 1.11.3.

我能够使用这里的文档页面来标识正确的rgdal版本: https://www.rdocumentation.org/packages/rgdal/versions/1.2-20

I was able to identify the correct version of rgdal using the documentation page here: https://www.rdocumentation.org/packages/rgdal/versions/1.2-20

然后我使用 devtools 软件包安装正确的版本:

Then I used the devtools package to install the correct version:

require(devtools)
install_version("rgdal", version="1.2-20")

此页面包含有关安装较早版本的R软件包的有用信息: https://support.rstudio.com/hc/en-us/articles/219949047-Installing-older-versions-of-packages

This page has helpful information on installation of earlier versions of R packages: https://support.rstudio.com/hc/en-us/articles/219949047-Installing-older-versions-of-packages

我尝试从源代码和程序包管理器安装gdal的最新版本,但是当我尝试安装 rgdal 的步骤时,仍然出现各种错误.

I attempted installing more recent versions of gdal both from source and with my package manager but continued to get various errors when I got to the step of trying to install rgdal.

我不知道的是为什么在尝试进行gdal升级时总是出现错误.

What I don't know is why I kept getting errors when trying to work with gdal upgrades.

这篇关于安装rgdal-回溯rgdal版本与更新gdal版本,以及如何?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆