[R-sig-Geo] R-sig-Geo Digest, Vol 50, Issue 4

Marco Helbich marco.helbich at gmx.at
Sat Oct 6 14:32:51 CEST 2007


Dear Kam Tin Seong,

try something like this:
w <- readShapePoly("xxxx.shp")
W <-as(as(w, "SpatialPolygons"), "owin")  # polygon window
plot(W)
pts.ppp <- as.ppp(xykoord, W) # xykoord=point pattern
summary(pts.ppp)
plot(pts.ppp)

Best regards
Marco
______________________________

Marco Helbich
Institute for Urban and Regional Research, 
Austrian Academy of Sciences 
Postgasse 7/4/2, A-1010 Vienna, Austria
phone: +43 (1) 51581-3494
mail: marco.helbich (at) oeaw.ac.at 

> 
> ------------------------------
> 
> Message: 4
> Date: Fri, 5 Oct 2007 09:22:46 +0800
> From: "KAM Tin Seong" <tskam at smu.edu.sg>
> Subject: Re: [R-sig-Geo] Import polygon shp into spatstat
> To: <r-sig-geo at stat.math.ethz.ch>
> Message-ID:
> <FA3090E732DC6A4EB8E2D875EEB486A562CE2D at EX01.staff.smu.edu.sg>
> Content-Type: text/plain
> 
> Hi all,
> 
> I have a polygon drawing in shpefile format and would like to use this
> drawing to define the boundary of my study area using spatstat.  Can
> someone advice me how to go about doing it?
> 
> Dr Kam Tin Seong 
> Practice Associate Professor 
> School of Information Systems 
> 
> Singapore Management University 
> 80 Stamford Road 
> Singapore 178902 
> e-mail: tskam at smu.edu.sg 
> DID: + 65 6828 0932
> 
>




More information about the R-sig-Geo mailing list