[R-sig-Geo] clip a SpatialPolygonsDataFrame

Laetitia Blanc blanc.laetitia.esr34 at gmail.com
Thu Aug 5 19:58:52 CEST 2010


Roger Bivand,

i tried the method with xlim and ylim and it works when i just plot my map
alone. What i try to do is to insert this map in my animation. Here is the
code of my animation :

pres.ani <- function() 
{ 
for (i in 1:length(unique(d$an))) { 
image(res[,,i],xlab='',ylab='',main=unique(d$an)[i]) 
contour(res[,,i],add=T) 
#points(d3[[i]]) 
Sys.sleep(.5) 
} 

} 
ani.start(interval=.5,title = "movie presence lynx", outdir = getwd()) 

pres.ani() 
ani.stop() 

res[,,i] is my KDE. When i create this animation, the x and y axes range of
the window is 0:1. How can i put my map (coordinate system : Lambert II) as
a background  in this animation ?
I hope it's enough clear...

Thank you for your help.

-- 
View this message in context: http://r-sig-geo.2731867.n2.nabble.com/clip-a-SpatialPolygonsDataFrame-tp5376909p5377623.html
Sent from the R-sig-geo mailing list archive at Nabble.com.



More information about the R-sig-Geo mailing list