Skip to content

Commit e4e08c8

Browse files
committed
added new plot logic
1 parent a1721d9 commit e4e08c8

File tree

16 files changed

+89
-43
lines changed

16 files changed

+89
-43
lines changed

code/core/acc_new.R

Lines changed: 26 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -84,32 +84,46 @@ main <- function() {
8484

8585
try({
8686
GGIR(
87+
# ==== Initialization ====
8788
mode = 1:6,
8889
datadir = datadir,
8990
outputdir = outputdir,
9091
studyname = "boost",
9192
overwrite = FALSE,
92-
do.report = c(2, 4, 5, 6),
93-
visualreport = TRUE,
94-
old_visualreport = FALSE,
95-
windowsizes = c(5, 900, 3600),
9693
desiredtz = "America/Chicago",
9794
print.filename = TRUE,
98-
dayborder = 0,
9995
idloc = 2,
96+
save_ms5rawlevels = "csv"
97+
98+
# ==== Part 1: Data loading and basic signal processing ====
99+
do.report = c(2, 4, 5, 6),
100100
epochvalues2csv = TRUE,
101-
ignorenonwear = TRUE,
102101
do.ENMO = TRUE,
103102
acc.metric = "ENMO",
103+
windowsizes = c(5, 900, 3600),
104+
105+
# ==== Part 2: Non-wear detection ====
106+
ignorenonwear = TRUE,
107+
108+
# ==== Part 3: Sleep detection (optional if using external file) ====
109+
# Uncomment the below if using external sleep log:
110+
# loglocation = "/Shared/vosslabhpc/Projects/BOOST/InterventionStudy/3-experiment/data/act-int-test/sleep.csv",
111+
# colid = 1,
112+
# coln1 = 2,
113+
# sleepwindowType = "SPT",
114+
115+
# ==== Part 4: Physical activity summaries ====
116+
timewindow = c("WW", "MM", "OO"),
117+
118+
# ==== Part 5: Day-level summaries ====
104119
hrs.del.start = 4,
105120
hrs.del.end = 3,
106121
maxdur = 9,
107-
loglocation = "/Shared/vosslabhpc/Projects/BOOST/InterventionStudy/3-experiment/data/act-int-test/sleep.csv",
108-
colid = 1,
109-
coln1 = 2,
110-
sleepwindowType = "SPT",
111-
timewindow = c("WW", "MM", "OO"),
112-
part6CR = TRUE
122+
123+
# ==== Part 6: CR and other metrics ====
124+
part6CR = TRUE,
125+
visualreport = TRUE,
126+
old_visualreport = FALSE
113127
)
114128
})
115129
}

code/docs/gg.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,5 @@ Character (default = c()). Directory where the output needs to be stored. Note t
1616
Observational has 1 wear period for 7 days. Intervention has 4 total wear periods for 10 days each.
1717

1818

19+
# wear period valid check
20+
- as long as unidentified is < 8 hours
2.71 KB
Loading
854 Bytes
Loading
758 Bytes
Loading
722 Bytes
Loading
821 Bytes
Loading
957 Bytes
Loading
768 Bytes
Loading
725 Bytes
Loading

0 commit comments

Comments
 (0)