Dear forum,

 

I would like to use the kernel2d or spkernel2d in the Splancs-package, but
it does not recognize my polygon data.

 

"Error in kernel2d(as.points(ptsbin), polygonprov, h0 = 2, nx = 100,  : " is
the error message.

        Invalid poly argument

 

The data are defined as follows:

polgonprov<-list(x=polyprov$X, y=polyprov$Y) with X and Y coordinates in the
Lambert1972 notation. The points are defined in the same coordinate system
and it does recognize them, so I don't suppose that is the problem. 

 

I can also draw the province polygon by:

plot(c(192800,254100),c(154100,221800),type="n")

polygon(polyprov$X,polyprov$Y)

 

Can someone help me with this? Or explain to me how exactly is the polygon
class defined in splancs? I also tried with

Polygonprov<-Polygon(list(x=polyprov$X,y:polyprov$Y)) but that does not seem
to work either.

 

Thanks already in advance.

Kind regards,

 

 

Elke

 

__________________________________

Elke Moons, PhD

Transportation Research Institute

Belgium

E-mail:  <mailto:[EMAIL PROTECTED]> [EMAIL PROTECTED]

 


        [[alternative HTML version deleted]]

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to