From 9a85f82ec60fb6771191e1fd064eababf28b534a Mon Sep 17 00:00:00 2001 From: Brian Helsel Date: Thu, 20 Jul 2023 21:40:33 -0500 Subject: [PATCH] Expand the .last_complete_epoch function --- R/get_timestamps.R | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/R/get_timestamps.R b/R/get_timestamps.R index 28907d9..7395364 100644 --- a/R/get_timestamps.R +++ b/R/get_timestamps.R @@ -1,3 +1,7 @@ +# Copyright © 2022 University of Kansas. All rights reserved. +# +# Creative Commons Attribution NonCommercial-ShareAlike 4.0 International (CC BY-NC-SA 4.0) + .get_timestamps <- function(raw, epoch, frequency, tz) { if("start_time" %in% names(attributes(raw))){ @@ -25,7 +29,7 @@ samples_per_epoch <- frequency * epoch - utils::tail(raw$time, samples_per_epoch * 3) %>% + utils::tail(raw$time, samples_per_epoch * 10) %>% lubridate::floor_date(paste(epoch, "sec")) %>% as.character(.) %>% rle(.) %>%