-
Notifications
You must be signed in to change notification settings - Fork 2
Home
cleangeo provides a set of utility tools to inspect spatial objects, facilitate handling and reporting of topology errors and geometry validity issues. Finally, it provides a geometry cleaner that will fix all geometry problems, and eliminate (at least reduce) the likelihood of having issues when doing spatial data processing.
With the aim to guarantee the sustainability of cleangeo, cleangeo is currently seeking for institutional or individual sponsors to fund the package development in order to (1) enhance and strenghten existing functionalities, (2) provide new features, and (3) ensure timeley maintenance and users support.
If you wish to sponsor cleangeo, do not hesitate to contact me
For citation, please use the DOI
Do you need support to use cleangeo
? You may consider to:
- ask on http://stackoverflow.com
- create a ticket in Github
Do you use cleangeo
? your feedback is welcome! You may consider to:
Table of contents
1. Overview
2. Package status
3. Success stories
4. Credits
5. Fundings
6. User guide
6.1 Install cleangeo
6.2 Inspect spatial objects
6.3 Clean spatial objects
7. Issue reporting
R provides a lot of facilities to read and manipulate spatial data. We can mention some packages such as:
-
sp
, which provides a set of classes and methods to handle spatial objects -
maptools
, a set of tools for reading and handling Spatial Objects -
rgdal
, which provides an interface to the well-known Geospatial Data Abstraction Library (GDAL) -
rgeos
, which provides an interface to the widely used Geometry Engine, Open Source (GEOS) library.
The main problem comes when spatial objects do not have valid geometries, or expose different types of geometry errors (e.g. orphaned holes), which prevents any easy spatial data processing.
cleangeo
was built in order:
- to facilitate handling and catching rgeos geometry issues
- to provide a tool to clean and validate the spatial objects, prior any geoprocessing
Check the [Change History] (https://github.com/eblondel/cleangeo/wiki/Change-History) which provides a list of fixes and improvements by milestone.
Check also the success stories to see how and where cleangeo is used!
While the cleangeo is still growing, it is worth mentioning that its user community is growing, and positive feedback and acknowledgments were provided about its use. Support was provided to users either by supplying examples and help or even by improving the package (enhancements, bug fixing).
Some projects using cleangeo
:
- Ocean Health Index
- UNHCR Iraq Information Management
- UN-FAO Fisheries Global Information System (FIGIS)
- EU FP7 CityPulse Project
Did you use cleangeo
in your work?
We would be very grateful if you can add a citation in your published work. By citing cleangeo
, beyond acknowledging the work, you contribute to make it more visible and guarantee its growing and sustainability. For this, please use the DOI
The cleangeo package is borned from a volunteer development initiative to facilitate cleaning of geometries from spatial objects in R, hence to allow a better and more accurate geoprocessing when performing geospatial analyses.
Currently, the project is seeking for funding opportunities in order to make the package growing with new functionalities, improvements, guarantee a quality maintenance of the R package and users support, hence ensuring the sustainability of the cleangeo project. If you wish to make a donation to acknowledge for the work accomplished so far, please contact us.
Package can be installed either from Github (latest)
install.packages("devtools")
Once the devtools package loaded, you can use the install_github to install cleangeo. By default, package will be installed from master
which is the current version in development (likely to be unstable).
require("devtools")
install_github("eblondel/cleangeo")
The latest release can be installed by the specifying the name of the release as ref
value in install_github
. See https://github.com/eblondel/cleangeo/releases for the list of releases (note: a release is generally made when package is published to CRAN).
require("devtools")
install_github("eblondel/cleangeo", ref= "v0.1-2")
Let's load some sample data in R:
require(maptools)
file <- system.file("extdata", "example.shp", package = "cleangeo")
sp <- readShapePoly(file)
cleangeo
first allows to inspect spatial objects, and detect eventual issues:
sp.report <- clgeo_CollectionReport(sp)
sp.summary <- clgeo_SummaryReport(sp.report)
The output indicates that 2 spatial objects have a problem of geometry validity.
Cleaning spatial objects is very easy:
sp.fixed <- clgeo_Clean(sp, verbose = TRUE)
Let's analyse the new spatial objects:
sp.fixed.report <- clgeo_CollectionReport(sp.fixed)
sp.fixed.summary <- clgeo_SummaryReport(sp.fixed.report)
And that's it! Now your spatial objects have clean geometries, you can safely do some spatial data processing on it.
Issues can be reported at https://github.com/eblondel/cleangeo/issues