inbo / n2khab

R package with preprocessing functions and standard reference data for Flemish Natura 2000 (N2K) habitat (HAB) analyses
https://inbo.github.io/n2khab
GNU General Public License v3.0
2 stars 1 forks source link

Be explicit about the attribute-geometry relationship of sf objects #178

Open florisvdh opened 8 months ago

florisvdh commented 8 months ago

This is needed to prevent warnings in geometry operations, assuming a constant attribute throughout each geometry. More information: https://r-spatial.org/book/05-Attributes.html, https://r-spatial.github.io/sf/reference/sf.html.

In many cases, adding %>% st_sf(agr = "identity") will be sufficient for the sf objects returned by n2khab.