[R-sig-Geo] neighborly ordering of spdf data/spacetime

Edzer Pebesma edzer.pebesma at uni-muenster.de
Fri May 25 10:48:56 CEST 2012


Chris, I don't exactly understand why the ordering of your polygons
matter. Do the overlap, when plotting them?

On 05/24/2012 10:54 PM, Chris English wrote:
> 
> Hello,
> I am exploring some US county level housing data.  I started with New Jersey and built a SPDF and subsequently a STFDF.  Data and spatial were in alphabetical order that madematching straight forward.  
> The problem arises that alphabetically named spatial attributes, i.e. atlantic, bergen (counties),are not close physically, indeed, often not neighbors.
> When trying to plot a variable of interest among some neighboring counties instead of the wholestate, hudson, bergen, essex, for example, many other counties have to be plotted because the SPDF was created in alphabetical order.
> I've spent the afternoon looking at spdep and deriving various neighbor, for example:
>  > nj_cty_hu_nb <- poly2nb(nj_cty_2.spdf)> summary(nj_cty_hu_nb)Neighbour list object:Number of regions: 21 Number of nonzero links: 82 Percentage nonzero weights: 18.5941 Average number of links: 3.904762 Link number distribution:
> 2 3 4 5 6 7 3 5 7 4 1 1 3 least connected regions:cape may hudson salem with 2 links1 most connected region:morris with 7 links
> Basically I'm wondering if someone can suggest how I might go back and recreate my spatial polygonsobject ordered by a more optimal neighbor approach and thence construct a new spdf based upon amore neighborly order than a-z.  
> Thanks in advance,Chris
> 
>    		 	   		  
> 	[[alternative HTML version deleted]]
> 
> _______________________________________________
> R-sig-Geo mailing list
> R-sig-Geo at r-project.org
> https://stat.ethz.ch/mailman/listinfo/r-sig-geo

-- 
Edzer Pebesma
Institute for Geoinformatics (ifgi), University of Münster
Weseler Straße 253, 48151 Münster, Germany. Phone: +49 251
8333081, Fax: +49 251 8339763  http://ifgi.uni-muenster.de
http://www.52north.org/geostatistics      e.pebesma at wwu.de



More information about the R-sig-Geo mailing list