Skip to content
forked from paleolimbot/geos

Vectorized geometries and low-level GEOS access

Notifications You must be signed in to change notification settings

SymbolixAU/geom

 
 

Repository files navigation

geom

Lifecycle: experimental R-CMD-check Codecov test coverage

The goal of geom is to provide low-level access to the GEOS library, supporting several common input/output formats to facilitate geoprocessing in R. This package tries to solve the “hard” problems associated with wrapping a C/C++ library, exposing an R API and a C++ API that can be used in dependency packages.

Installation

You can install the development version from GitHub with:

# install.packages("devtools")
devtools::install_github("paleolimbot/geom")

If you can load the package, you’re good to go!

library(geom)

Example

Create a line, buffer it, and plot!

line <- geo_wkt("LINESTRING (30 10, 10 30, 40 40)")
geo_plot(geos_buffer(line, width = 4), col = "grey90")
geo_plot_add(line)

Philosophy

  • Minimize conversion between in-memory formats
  • Operate one feature at a time
  • Use vctrs where possible to make sure that geometry vectors can exist in a data frame.
  • Clear size and type stability
  • Don’t consider spatial constraints (That’s what sf is so good at!)

About

Vectorized geometries and low-level GEOS access

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C++ 61.1%
  • R 36.8%
  • M4 2.0%
  • C 0.1%