Skip to content
Prev 25629 / 29559 Next

sp::disaggregate() does not seem to add the necessary "comment" attribute to identify holes if Polygons does not contain exactly 1 polygon with 0 or 1 holes

Roger,

This looks great, and I will try it out ASAP.  I do have one reservation
though --- it seems you are using createSPComment() to reconstruct the
comments, and I have seen some discussion that that may not be reliable in all
cases (e.g. if the initial polygons are wonky in some way).  I don't know a
lot about this, but is it possible that it would be preferable to parse and
appropriately disaggregate the original comments strings (if they exist), so
as to deal slightly more smoothly with such cases (i.e., the polygons would
still be wonky, but at least the hole/polygon matching would track with
whatever was in the original data)?

I also had no success using createSPComment to fix disaggregate()'s output
previously, even though my polygons are perfectly non-wonky, so I am perhaps a
little more untrusting of it than I should be.  But I'll let you know how this
version works with my data.  Thanks for addressing this so quickly!

 - Anne
On 04/28/2017 12:11 PM, Roger Bivand wrote:
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: OpenPGP digital signature
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20170428/11a2e103/attachment.sig>