Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
edzer committed Apr 10, 2024
1 parent 242c91e commit d9e84dd
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: stars
Title: Spatiotemporal Arrays, Raster and Vector Data Cubes
Version: 0.6-5
Version: 0.6-6
Authors@R:
c(person(given = "Edzer",
family = "Pebesma",
Expand Down
4 changes: 2 additions & 2 deletions R/aggregate.R
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ aggregate.stars = function(x, by, FUN, ..., drop = FALSE, join = st_intersects,
dims = dim(d)

agr_grps = function(x, grps, uq, FUN, ...) {
do.call(rbind, lapply(uq, function(i) {
do.call(cbind, lapply(uq, function(i) {
sel <- which(grps == i)
if (!isTRUE(any(sel)))
rep(NA_real_, ncol(x))
NA_real_
else
apply(x[sel, , drop = FALSE], 2, FUN, ...)
}
Expand Down

0 comments on commit d9e84dd

Please sign in to comment.