clean_logs {ARUtools}R Documentation

Extract log data from BAR-LT log files

Description

Process BAR-LT log files into a data frame reflecting metadata, schedule information, and events. Events are time-stamped logs of either GPS fixes (lat and lon) or recordings (rec_file, rec_size, rec_end).

Usage

clean_logs(log_files, return = "all", progress = TRUE)

Arguments

log_files

Character vector of log files to process.

return

Character. What kind of data to return, GPS fixes ("gps"), recording events ("recordings") or "all" (default).

progress

Logical. Whether to use purrr::map() progress bars (default TRUE).

Details

Note that log files can have glitches. If there is no start time for a recording (generally when there is a problem and no recording is made), the date_time value for that recording will be the same as the rec_end time.

Because the BAR-LT units adjust their time according to the GPS locations, all times are in "local" to that area.

Value

Data frame containing

Examples


# Replace "my_project_folder" with your directory containing your recordings and logfiles
log_files <- fs::dir_ls("my_project_folder", recurse = TRUE, glob = "*logfile*")
log_files
logs <- clean_logs(log_files)

log_files <- "../ARUtools - Extra/aru_log_files/P028/1A_BARLT10962/logfile_00010962_SD1.txt"

clean_logs(log_files)
clean_logs(log_files, return = "gps")
clean_logs(log_files, return = "recordings")

log_files <- fs::dir_ls("../ARUtools - Extra/aru_log_files/", recurse = TRUE, glob = "*logfile*")

l <- clean_logs(log_files)


[Package ARUtools version 0.7.2 Index]