Skip to content

Commit

Permalink
only expand varnum_event if length is less than typical day length #653
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentvanhees committed Dec 2, 2024
1 parent 3cd47b9 commit 17c4aba
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion R/g.analyse.perday.R
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@ g.analyse.perday = function(ndays, firstmidnighti, time, nfeatures,
# Then also extract count metric

varnum_event = as.numeric(as.matrix(vari[,ExtFunColsi]))
if (NRV != length(averageday[, ExtFunColsi])) {
if (NRV < length(averageday[, ExtFunColsi])) {
if (di == 1) {
varnum_event = c(averageday[1:abs(deltaLength), ExtFunColsi], varnum_event)
} else {
Expand Down

0 comments on commit 17c4aba

Please sign in to comment.