Published July 22, 2026
| Version v0.1.3
Software
Open
axR: Interfacing and Retrieving Data from Accelerometer Devices
Authors/Creators
- 1. Northumbria University, Circadia Lab
- 2. Northumbria University
Description
✨ New features
axivity_stage_device()-- a single convenience function to configure a device end-to-end for a participant deployment (accelerometer rate/range, deployment window, session ID, metadata) and commit it withaxivity_reset(), rather than calling the fouraxivity_set_*()functions plusaxivity_reset()separately. The deployment window can be given as explicitstart/stopPOSIXctvalues or asstart+duration. Deliberately does not allowreset_level = "none", since that would leave the staged settings only partially committed; users who need that level of control can still call the individualaxivity_set_*()functions andaxivity_reset()themselves.read_acttrust()-- parses a Condor Instruments ActTrust.txtactigraphy export directly, ported from zeitR as the first step toward making axR a general, device-agnostic actigraphy import layer (mirroringaxivity_read_cwa()for the Axivity side). Deliberately a device-format parser only: returns the file's own epoch columns (datetime,activity,int_temp,ext_temp,ZCMn,light) with ametadataattribute, and adds no pipeline-specific columns or classes -- downstream packages (e.g. zeitR) are expected to wrap this themselves, the same wayzeitR::read_axivity()already wrapsaxivity_read_cwa(). zeitR's ownread_acttrust()is unchanged for now; it will become a thin wrapper around this one in a follow-up.
📦 Dependencies
- Added
cliandlubridateto Imports, forread_acttrust()'s error/warning messages and flexible date-time parsing respectively. New internalaxr_abort()/axr_warn()/axr_inform()message helpers and a%||%operator (R/utils.R) mirror zeitR's ownR/utils.R, so message style stays consistent across the ecosystem as more parsers move into axR.
🧪 Tests
axivity_stage_device()rejectingreset_level = "none"before touching a device -- the one branch of the function testable without hardware, matching the rest of the suite.read_acttrust(): header metadata and epoch-data parsing against a synthetic export fixture; optional columns (ext_temp/ZCMn/light) defaulting toNAwhen absent from the export; missing-file, missingDATE/TIMEheader, and missing-required-column error paths. No real participant data needed -- synthetic fixtures built inline, per the no-permanently-skipped-tests policy.
⚠️ Known limitations
read_acttrust()'s parsing logic (header parsing, column mapping, date coercion) is a direct, line-for-line port of zeitR'sread_acttrust(), which has already been exercised against real Condor ActTrust recordings as part of zeitR's own Vallim parity test suite -- that track record carries forward with the port. What's new here and only covered by synthetic fixtures so far is the port itself: the droppedstate/offwrist/sleepcolumns andzeitr_acttrustclass (this function is a device-format parser only, by design -- see above), and the switch from zeitR'scli-basedzeitr_abort()to axR's ownaxr_abort(). The vignette's "Reading ActTrust files" section stayseval = FALSEpending verification of the port specifically against a real export.
📚 Documentation
- README and
vignette("axR")updated forread_acttrust(): features list, dependencies table, project structure, and a new "Reading ActTrust files" vignette section alongside the existing.cwaone. The "dumb pipe" scope note now covers both parsers as deliberate exceptions. The vignette section defaults toeval = FALSElike the rest of the doc, pending verification against a real ActTrust export.
Notes
Files
circadia-bio/axR-v0.1.3.zip
Files
(316.6 kB)
| Name | Size | Download all |
|---|---|---|
|
md5:1c2603f52fcbd344350cca58337a37c8
|
316.6 kB | Preview Download |
Additional details
Related works
- Is supplement to
- Software: https://github.com/circadia-bio/axR/tree/v0.1.3 (URL)
Software
- Repository URL
- https://github.com/circadia-bio/axR