[R-sig-Geo] Fwd: Divide Voronoi cell using azimuth in R

Zhang Jiaqiang zhangjiaqiang at gmail.com
Tue Sep 8 09:54:58 CEST 2015


Hello All,

Here is my code to generate some sample data for my question. As well as a
ggplot picture of voronoi.

What I want to do is divide each voronoi cell(the polygon in the center
which has closure edge ) into three cells(sectors).


​> head(data)

  site      lng      lat sector azimuth kpiA
1    a 103.8504 1.315139     a1       0   10
2    a 103.8504 1.315139     a2     120   20
3    a 103.8504 1.315139     a3     240   30
4    b 103.8481 1.321613     b1      50   40
5    b 103.8481 1.321613     b2     190   50
6    b 103.8481 1.321613     b3     320   60
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20150908/3eeb8922/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Rplot.png
Type: image/png
Size: 34242 bytes
Desc: not available
URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20150908/3eeb8922/attachment.png>


More information about the R-sig-Geo mailing list