Read an actigraphy file into a zeitr_recording object
Source:R/read_actigraphy.R
read_actigraphy.RdA device-agnostic wrapper that reads a raw actigraphy file and returns a
zeitr_recording object with $epochs (a tidy tibble) and $metadata
(a named list of device and recording information).
Arguments
- path
character(1). Path to the raw actigraphy file.- device
character(1). Device type. One of"acttrust"(default). Additional devices will be added in future versions.- tz
character(1). Recording time zone passed to the underlying reader. Default is"UTC".- ...
Additional arguments forwarded to the device-specific reader (e.g.
encodingforread_acttrust()).
Value
A zeitr_recording S3 object — a named list with:
$epochsA tibble with one row per epoch and columns
datetime,activity,int_temp,ext_temp,ZCMn,state,offwrist,sleep.$metadataA named list with
subject,device_id,device_model,firmware_version,interval_s,source_file, andparticipant_id(derived from the filename stem).
See also
read_actigraphy_dir() to read a whole directory at once.