Skip to content

Commit

Permalink
fix warn message and station assignment in anlz_fibmatrix
Browse files Browse the repository at this point in the history
  • Loading branch information
fawda123 committed Sep 30, 2024
1 parent a92ab8b commit aa9bbfe
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions R/anlz_fibmatrix.R
Original file line number Diff line number Diff line change
Expand Up @@ -189,8 +189,9 @@ anlz_fibmatrix <- function(fibdata, yrrng = NULL, stas = NULL, bay_segment = NUL
chk <- !stas %in% stasval

# check if some stations valid for lagyr
if(sum(chk) > 0 & sum(chk) < length(chk) & is.null(bay_segment) & warn){
warning('Stations with insufficient data for lagyr: ', paste(stas[chk], collapse = ', '))
if(sum(chk) > 0 & sum(chk) < length(chk) & is.null(bay_segment)){
if(warn)
warning('Stations with insufficient data for lagyr: ', paste(stas[chk], collapse = ', '))
stas <- stas[!chk]
}

Expand Down

0 comments on commit aa9bbfe

Please sign in to comment.