[prev in list] [next in list] [prev in thread] [next in thread]
List: r-sig-geo
Subject: [R-sig-Geo] Post Question
From: Rachel via R-sig-Geo <r-sig-geo () r-project ! org>
Date: 2017-06-03 13:44:23
Message-ID: 2007205613.1324427.1496497463253 () mail ! yahoo ! com
[Download RAW message or body]
I would like to post this question:
I am trying to figure out how to reassign small polygons to its nearest neighbor in R \
(similar to gdal_sieve.py function). I created a spatial polygon file from a \
classified gridded dataset using the grid2polygons function in R. I would now like to \
take that polygon file and merge any polygons containing less than 6 pixels with its \
nearest largest neighbor. In the image link (https://i.stack.imgur.com/6BLvP.jpg), \
you can see an example of small polygons circled in blue. I would like those merged \
with the larger surround polygon. Alternatively, if there is a way to create a \
minimum threshold of 6 clumped pixels prior to the conversion to polygon stage, any \
suggestions for that method would be great as well. There is a function in Gdal: \
gdal_sieve.py that can do exactly this (http://www.gdal.org/gdal_sieve.html) if you \
would like to get an idea of exactly what I would like to do. Does anyone know of a \
way to do this in R? [[alternative HTML version deleted]]
_______________________________________________
R-sig-Geo mailing list
R-sig-Geo@r-project.org
https://stat.ethz.ch/mailman/listinfo/r-sig-geo
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic