If it is of any help, you might want to take a look at this guide:

"Creating Maps for Publication using R Graphics"
http://www.nceas.ucsb.edu/scicomp/GISSeminar/UseCases/MapProdWithRGraphics/OneMapProdWithRGraphics.h
tml

The second example demonstrates how to visualize a remote sensing band using 
grey levels and then
overlay various vector layers.

Tom Hengl
http://spatial-analyst.net 



-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of
Roger Bivand
Sent: dinsdag 20 mei 2008 16:38
To: Monica Pisica
Cc: r-sig-geo@stat.math.ethz.ch
Subject: Re: [R-sig-Geo] displayDataset command

On Tue, 20 May 2008, Monica Pisica wrote:

>
> Hi,
>
> I am trying to display a geotiff using displayDataset command from rgdal 
> ..... which i can do pretty successfully but i cannot display axes for 
> my map .... i tried to use axes = TRUE and i got the error that axes is 
> matched by multiple arguments and if i try to set xaxs and yaxs as equal 
> to "i" or "r" they are simply ignored .....
>
> Suppose my geotiff is named d1 ...
> x <- GDAL.open(d1)
> displayDataset(x, zlim = c(-2, 5.7), col = rainbow(20), xaxs = "r", yaxs 
> = "r")
>
> And i get a nice image display but no axes what so ever ;-)

If you look in the code, you'll see that axes are set to FALSE internally, 
and the drawing units are manipulated, so the graphics display does not 
know where they should go or which units they should be in. Since you can 
use output.dim= in readGDAL too, I'd go with

image(readGDAL(d1), col=grey.colors(20), axes=TRUE)

adding arguments to readGDAL() to decimate the image if there are many 
pixels. You don't get the color palette, though, but it could be retrieved 
if need be.

Roger

>
> I will really appreciate any help you can provide,
>
> Thanks,
>
> Monica
> _________________________________________________________________
> E-mail for the greater good. Join the i’m Initiative from Microsoft.
>
> ood
>       [[alternative HTML version deleted]]
>
>

-- 
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: [EMAIL PROTECTED]

_______________________________________________
R-sig-Geo mailing list
R-sig-Geo@stat.math.ethz.ch
https://stat.ethz.ch/mailman/listinfo/r-sig-geo

Reply via email to