Skip to content

Upcoming maptools retirement #5244

Closed
Closed
@yutannihilation

Description

@yutannihilation

A year ago, R-spatial announced rgdal, rgeos, and maptools will retire by the end of 2023.

https://r-spatial.org//r/2022/04/12/evolution.html

ggplot2 doesn't use rgdal, and just removed rgeos in #5242. However, maptools is still used in fortify.SpatialPolygonsDataFrame() (and the examples section of the document).

unioned <- maptools::unionSpatialPolygons(cp, attr[, region])

We need to decide how to deal with this. I think we have several options:

  1. Replace maptools::unionSpatialPolygons() with sf functions (convert to an sf object, transform it and convert back to an sp object)
  2. Remove the functionality related to maptools::unionSpatialPolygons()
  3. Drop fortify() methods for sp objects altogether

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions