ropensci-archive / wicket

:no_entry: ARCHIVED :no_entry: Utilities to Handle WKT Spatial Data
Other
9 stars 1 forks source link

centroid #11

Closed sckott closed 7 years ago

sckott commented 7 years ago

http://www.boost.org/doc/libs/1_47_0/libs/geometry/doc/html/geometry/reference/algorithms/centroid/centroid_2.html

another issue is i sometimes need to calculate centroid for WKT, doing this now with a Turf JS module https://github.com/ropensci/spocc/blob/master/inst/js/turf-centroid.js - but if can be added here easily, then ....

Ironholds commented 7 years ago

2D or 3D centroid?

Ironholds commented 7 years ago

Also at this point on a practical basis the hours have hit their limit, so I guess this would go into the ongoing-maintenance-and-new-features contract?

sckott commented 7 years ago

yeah, onto the new contract if all hrs up on 1st.

just 2D

Ironholds commented 7 years ago

Do you want universal support or just polygon support?

sckott commented 7 years ago

universal if doable, for 2D that is

Ironholds commented 7 years ago

Should now be testable as get_centroid (although I need to write tests)

sckott commented 7 years ago

Seems to work so far for polygons - does it only support POLYGON right now?

Ironholds commented 7 years ago

Right now, yes, but I can widen it out to the other supported types trivially (obviously GCs are...harder to do, but everything else..)

sckott commented 7 years ago

thanks, skipping GC seems good to me

Ironholds commented 7 years ago

Test now?

sckott commented 7 years ago

working on it

sckott commented 7 years ago

works good AFAICT