Skip to content

Commit

Permalink
abandon st_extract_geometry
Browse files Browse the repository at this point in the history
texas sf object is malformed, and warning suppression
for single type objects doesn't seem to work
  • Loading branch information
brodieG committed May 2, 2020
1 parent bb40e76 commit 2d8b676
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions R/objects.R
Original file line number Diff line number Diff line change
Expand Up @@ -880,9 +880,8 @@ ellipsoid = function(x = 0, y = 0, z = 0, a = 1, b = 1, c = 1,
#'
#' @param polygon `sf` object, "SpatialPolygon" `sp` object, or xy coordinates
#' of polygon represented in a way that can be processed by `xy.coords()`. If
#' an `sf` object contains non-polygon geometries, those will be dropped. If
#' the latter type of polygon is open, it will be closed by adding an edge from
#' the last point to the first.
#' xy-coordinate based polygons are open, they will be closed by adding an
#' edge from the last point to the first.
#' @param x Default `0`. x-coordinate to offset the extruded model.
#' @param y Default `0`. y-coordinate to offset the extruded model.
#' @param z Default `0`. z-coordinate to offset the extruded model.
Expand Down Expand Up @@ -1112,7 +1111,6 @@ extruded_polygon = function(polygon = NULL, x = 0, y = 0, z = 0, plane = "xz",
if(!"sf" %in% rownames(utils::installed.packages())) {
stop("sf package required when handling sf objects")
}
polygon = sf::st_collection_extract(polygon, "POLYGON")
poly_info = sf::st_drop_geometry(polygon)
polygon = sf::as_Spatial(polygon)
if(!is.null(data_column_top)) {
Expand Down

0 comments on commit 2d8b676

Please sign in to comment.