From: mdsumner at gmail.com
Date: Tue, 14 Apr 2015 15:18:01 +0000
Subject: Re: [R] plotting rasters - no plot, no error
To: pisicandru at hotmail.com; r-help at r-project.org
On Wed, 15 Apr 2015 at 01:16 Michael Sumner
<mdsumner at gmail.com<mailto:mdsumner at gmail.com>> wrote:
On Wed, 15 Apr 2015 at 00:50 Monica Pisica
<pisicandru at hotmail.com<mailto:pisicandru at hotmail.com>> wrote:
Hi,
computers. On one i can plot using the plot function a raster in geotif
format, on the other it plots only the axis, an empty color bar and no
raster what so ever without generating any errors or warnings. So i
suspect something is not installed properly, but i don't know what. Do
you have any clues? I would really appreciate any insights. I need some
instructions i can pass on to an IT person since i don't have rights on
the computer that does not plot the raster.
Hello, can you try these on both systems and see if there's a difference?
library(raster)
plot(raster(volcano))
plot(raster(volcano), useRaster = TRUE)
Ugh, sorry I meant to try this:
plot(raster(volcano), useRaster = FALSE)
otherwise both calls are equivalent.
Cheers, Mike.
the useRaster argument refers to use of graphics::rasterImage rather
than image.defaul under (package) raster's hood.
Cheers, Mike.
On both computers i can plot lines, points, polygons, as graphic
objects or shapefiles.
The first PC that plots the raster:
Sys.info()
sysname release
version
Service Pack 1"
nodename machine
login
"NODENAME" "x86-64"
"LOGIN"
user effective_user
"MONICA" "MONICA"
R.Version()
$platform
[1] "x86_64-w64-mingw32"
$system
[1] "x86_64, mingw32"
$version.string
[1] "R version 3.1.3 (2015-03-09)"
$nickname
[1] "Smooth Sidewalk"
Libraries i loaded: maptools, raster, rgdal, sp, CircStats, rgeos, stringr
The computer that does not plot the raster:
Sys.info()
sysname release
version nodename
Service Pack 1" "NODENAME"
machine login
user effective_user
"x86-64" "MONICA"
"MONICA" "MONICA"
R.Version()
$platform
[1] "x86_64-w64-mingw32"
$system
[1] "x86_64, mingw32"
$version.string
[1] "R version 3.1.3 (2015-03-09)"
$nickname
[1] "Smooth Sidewalk"
Libraries i loaded: maptools, raster, rgdal, sp, CircStats, rgeos, stringr
again thanks so much,
Monica