Skip to content

Commit

Permalink
prepare version that suppresses new variables #653
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentvanhees committed Nov 19, 2024
1 parent eac1bb1 commit a865632
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
3 changes: 0 additions & 3 deletions R/g.analyse.perfile.R
Original file line number Diff line number Diff line change
Expand Up @@ -308,14 +308,11 @@ g.analyse.perfile = function(I, C, metrics_nav,
}
daysummary = data.frame(value = daysummary, stringsAsFactors = FALSE)
names(daysummary) = ds_names

# remove double columns with 1-6am variables
columnswith16am = grep("1-6am", x = colnames(daysummary))
if (length(columnswith16am) > 1) {
daysummary = daysummary[,-columnswith16am[2:length(columnswith16am)]]
}


# tidy up filesummary object
mw = which(is.na(filesummary) == T)
mw = c(mw, grep(pattern = "NaN", x = filesummary))
Expand Down
9 changes: 9 additions & 0 deletions R/g.report.part2.R
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,15 @@ g.report.part2 = function(metadatadir = c(), f0 = c(), f1 = c(), maxdur = 0,
names(dayEVENTSUMMARY) = gsub(pattern = "ExtFunEvent_", replacement = "", x = names(dayEVENTSUMMARY))
daySUMMARY = daySUMMARY[,NotEventVars]
dayEVENTSUMMARY_clean = tidyup_df(dayEVENTSUMMARY)
#-----------------------------------------------------------------------
# November 2024:
# TEMPORARILY REMOVE ALL NEW STEP VARIABLES TO FACILITATE
# MERGE OF MOST WORK RELATED TO EVENT DETECTION WITH MASTER BRANCH
# WITHOUT RELEASING NEW VARIABLES YET
dayEVENTSUMMARY_clean = dayEVENTSUMMARY_clean[, grep(pattern = "cad_|_cad|Bout_|accatleast|count_acc",
x = colnames(dayEVENTSUMMARY_clean),
invert = TRUE)]
#-----------------------------------------------------------------------
data.table::fwrite(x = dayEVENTSUMMARY_clean,
file = paste0(metadatadir, "/results/part2_day", eventName, "summary.csv"),
row.names = F, na = "")
Expand Down

0 comments on commit a865632

Please sign in to comment.