Skip to content

Commit f3e93b7

Browse files
committed
rm stars
1 parent 6401ea6 commit f3e93b7

File tree

3 files changed

+11
-12
lines changed

3 files changed

+11
-12
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import:
1212
Imports:
1313
magrittr,
1414
stringr, purrr,
15-
sf, stars,
15+
sf,
1616
terra,
1717
tidyselect,
1818
data.table, dplyr,

NAMESPACE

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ export(plot)
3030
export(rast)
3131
export(rast2SpatialGrid)
3232
export(rast2colormap)
33-
export(rast2poly)
3433
export(rast_array)
3534
export(rast_cellId)
3635
export(rast_df)

R/tools_rast.R

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,16 @@
55
# as(r, "SpatialPolygonsDataFrame")
66
# }
77

8-
#' @export
9-
rast2poly <- function(r, crs = 4326) {
10-
sf_poly <- suppressWarnings({
11-
sf::st_as_sf(stars::st_as_stars(r),
12-
as_points = FALSE, merge = TRUE
13-
) %>% sf::st_make_valid() # %>% sf::as_Spatial()
14-
})
15-
sf::st_crs(sf_poly) <- crs
16-
sf_poly
17-
}
8+
# #' @export
9+
# rast2poly <- function(r, crs = 4326) {
10+
# sf_poly <- suppressWarnings({
11+
# sf::st_as_sf(stars::st_as_stars(r),
12+
# as_points = FALSE, merge = TRUE
13+
# ) %>% sf::st_make_valid() # %>% sf::as_Spatial()
14+
# })
15+
# sf::st_crs(sf_poly) <- crs
16+
# sf_poly
17+
# }
1818

1919

2020
#' @export

0 commit comments

Comments
 (0)