An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20101120/29f455f0/attachment.pl>
difficulty loading package "sp"
3 messages · Michael Marsh, Roger Bivand, Rolf Turner
On Sat, 20 Nov 2010, Mike Marsh wrote:
Hello all, This is my first message to this list. I'm reading "Applied spatial data analysis with R", and trying to install "sp". I went to http://cran.r-project.org/ then to Packages, but did not find "sp" I found and downloaded sp_0.9-72.zip <http://cran.r-project.org/bin/windows/contrib/r-release/sp_0.9-72.zip>from the page linked to CRAN Task View Analysis of Spatial Data, moved the zipped package to my library folder under R-2.8.1, and unzipped it, obtaining folder sp_0.9-72 I opened R in folder library, and called
No, this is not how you install binary contributed packages on Windows.
You use the Packages -> menu item, choosing sp from the (long) list that
appears after you have chosen a CRAN mirror. Alternatively, you can simply
enter install.packages("sp") at the console prompt, you will be asked for
a CRAN mirror. Never mess with the R library folders, its contents and
index are updated within R, and are not for users to meddle with.
You are also running R 2.8.1 (current is 2.12.0), so installing manually
(had you done it properly by downloading the correct zip archive and using
the Packages -> Install from local zip file option) would only work for
the 2.8 binary build of the package:
http://cran.r-project.org/bin/windows/contrib/2.8/sp_0.9-37.zip
but this should be selected automatically if you use the system correctly.
Hope this helps,
Roger
library(sp)
Error in library(sp) : there is no package called 'sp', version 0.9-72 then I tried
library(sp_0.9-72)
Error in library(sp_0.9 - 72) : 'package' must be of length 1 then I opened sp 0.9.-72 and moved folder sp to be under the parent directory, library
library(sp)
Error: This is R 2.8.1, package 'sp' needs >= 2.10.0 I tried "update.package"
update.packages(sp)
Error in update.packages(sp) : object "sp" not found
I then tried Update Packages(), which resulted in me updating a bunch of other packages, but unfortunately left them in C:\WINDOWS\Temp\RtmpmtERQd\downloaded_packages, and considering my success so far, I'm afraid to move them or touch them. I was running R-2.8.0 last year when I took Jon Bakker's course "Analytical methods for community ecology", but upgraded this year to 2.8.1. Not knowing where to find a package "sp" that is >= 2.10.0, I turn to you for help. Thanks, Mike [[alternative HTML version deleted]]
_______________________________________________ R-sig-Geo mailing list R-sig-Geo at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo
Roger Bivand Economic Geography Section, Department of Economics, Norwegian School of Economics and Business Administration, Helleveien 30, N-5045 Bergen, Norway. voice: +47 55 95 93 55; fax +47 55 95 95 43 e-mail: Roger.Bivand at nhh.no
On 21/11/2010, at 4:25 PM, Mike Marsh wrote:
Hello all, This is my first message to this list. I'm reading "Applied spatial data analysis with R", and trying to install "sp". I went to http://cran.r-project.org/ then to Packages, but did not find "sp"
You can't have looked very hard.
I found and downloaded sp_0.9-72.zip <http://cran.r-project.org/bin/windows/contrib/r-release/sp_0.9-72.zip>from the page linked to CRAN Task View Analysis of Spatial Data, moved the zipped package to my library folder under R-2.8.1, and unzipped it, obtaining folder sp_0.9-72 I opened R in folder library, and called
library(sp)
Error in library(sp) : there is no package called 'sp', version 0.9-72 then I tried
library(sp_0.9-72)
Error in library(sp_0.9 - 72) : 'package' must be of length 1 then I opened sp 0.9.-72 and moved folder sp to be under the parent directory, library
library(sp)
Error: This is R 2.8.1, package 'sp' needs >= 2.10.0
You need to install the package before you try to load it.
I tried "update.package"
update.packages(sp)
Error in update.packages(sp) : object "sp" not found
Look at the error message. There is no object named "sp" in your
search path. You would need to to update.packages("sp") were this
the appropriate thing to do. Which it isn't. You haven't yet
(ever) installed sp, so how can you update it?
Try doing install.packages("sp").
I then tried Update Packages(), which resulted in me updating a bunch of other packages, but unfortunately left them in C:\WINDOWS\Temp\RtmpmtERQd\downloaded_packages, and considering my success so far, I'm afraid to move them or touch them. I was running R-2.8.0 last year when I took Jon Bakker's course "Analytical methods for community ecology", but upgraded this year to 2.8.1. Not knowing where to find a package "sp" that is >= 2.10.0, I turn to you for help.
The current version of R is 2.12.0. cheers, Rolf Turner