I have a set of points in .shp (ESRI, available here: http://ulozto.cz/xGqRVFrR/voronoi-zip). I would like to calculate Voronoi tesselation from the points, thus create polygons. So far, so good. However, points attribute table is not transferred automatically in R to Voronoi tesselation polygons during calculation (as is the case in ArsGIS).
Thus, depending points' spatial location I want to add points' attributes to my new Voronoi's polygons. I tried to used function
over(diagram.poly, bod.sp) but it creates data.frame, not polygon.
Please,
my code:
# exemple with my data library(sp) library(deldir) library(rgdal) library(maptools) # set directory wd
Thus, depending points' spatial location I want to add points' attributes to my new Voronoi's polygons. I tried to used function
over(diagram.poly, bod.sp) but it creates data.frame, not polygon.
Please,
- how to automatically add points' attributes to Voronoi polygon OR
- how to use resulting data.frame as my polygon's attribute table?
my code:
# exemple with my data library(sp) library(deldir) library(rgdal) library(maptools) # set directory wd