Skip to content

Commit

Permalink
Rename sleep_efficiency column in part 5 report, fixes #1157
Browse files Browse the repository at this point in the history
  • Loading branch information
vincentvanhees committed Jun 24, 2024
1 parent 87b07ef commit 7d11fee
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@

- Report part 5: fix bug that was introduced on 2024-Feb-19 in the calculation of wear percentage #1148

- Report part 5: Rename variable sleep_efficiency to sleep_efficiency_after_onset, #1157

- Vignette: Migrated many sections from main CRAN vignette to wadpac.github.io/GGIR/

# CHANGES IN GGIR VERSION 3.1-1
Expand Down
2 changes: 1 addition & 1 deletion R/g.part5_analyseSegment.R
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ g.part5_analyseSegment = function(indexlog, timeList, levelList,
# sleep efficiency
dsummary[si,fi] = length(which(ts$sibdetection[sse] == 1 &
ts$diur[sse] == 1)) / length(which(ts$diur[sse] == 1))
ds_names[fi] = "sleep_efficiency"; fi = fi + 1
ds_names[fi] = "sleep_efficiency_after_onset"; fi = fi + 1
#===============================================
# NAPS (estimation)
if (params_output[["do.sibreport"]] == TRUE & "nap1_nonwear2" %in% colnames(ts) &
Expand Down

0 comments on commit 7d11fee

Please sign in to comment.