Skip to content

Commit

Permalink
update anlz_fibmatrix to remove groups with years less than lagyr
Browse files Browse the repository at this point in the history
  • Loading branch information
fawda123 committed Oct 10, 2024
1 parent e64d0f4 commit 8d5efcd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Package: tbeptools
Title: Data and Indicators for the Tampa Bay Estuary Program
Version: 3.0.0.9000
Date: 2024-09-30
Date: 2024-10-10
Authors@R: c(
person(given = "Marcus",
family = "Beck",
Expand Down
4 changes: 4 additions & 0 deletions R/anlz_fibmatrix.R
Original file line number Diff line number Diff line change
Expand Up @@ -224,6 +224,10 @@ anlz_fibmatrix <- function(fibdata, yrrng = NULL, stas = NULL, bay_segment = NUL
.by = c('grp', 'yr')
) %>%
dplyr::arrange(grp, yr) %>%
dplyr::filter(
length(unique(yr)) >= lagyr,
.by = 'grp'
) %>%
dplyr::mutate(
sumgt = stats::filter(sumgt, rep(1, lagyr), sides = 1, method = 'convolution'),
tot = stats::filter(tot, rep(1, lagyr), sides = 1, method = 'convolution'),
Expand Down

0 comments on commit 8d5efcd

Please sign in to comment.