ClockLab-like MATLAB toolbox for chronobiological rhythm analysis from wrist actigraphy data.
%%{init: {'theme': 'base', 'themeVariables': {'primaryColor': '#E8F4FD', 'primaryBorderColor': '#7BA7C9', 'primaryTextColor': '#2C3E50', 'secondaryColor': '#FDF2E9', 'secondaryBorderColor': '#D4A574', 'secondaryTextColor': '#2C3E50', 'tertiaryColor': '#EAFAF1', 'tertiaryBorderColor': '#82C9A1', 'tertiaryTextColor': '#2C3E50', 'lineColor': '#5D6D7E', 'textColor': '#2C3E50', 'background': '#FFFFFF', 'mainBkg': '#E8F4FD', 'nodeBorder': '#7BA7C9', 'clusterBkg': '#F8F9FA', 'clusterBorder': '#BDC3C7', 'fontSize': '14px'}}}%%
flowchart LR
A[Actigraph Data]:::input --> B[Signal Conditioning]
B --> C[Cosinor Fitting]
C --> D[Rhythm Metrics]
D --> E[Periodogram]:::output
classDef input fill:#FDF2E9,stroke:#D4A574
classDef output fill:#EAFAF1,stroke:#82C9A1
A command-line MATLAB toolbox for analyzing circadian and ultradian rhythms from wrist actigraphy recordings. Provides a pipeline from raw data import through sleep scoring, periodogram analysis, cosinor fitting, detrended fluctuation analysis (DFA), and bout analysis -- comparable to commercial tools like ClockLab but open-source and extensible.
Supports multiple actigraph formats (Vivago, Daqtometer, CAMS, generic) and includes automated sleep scoring algorithms (Sadeh, Jean-Louis, Sazonov, Scripps).
- Data import -- Vivago, Daqtometer, CAMS, and generic text/MAT formats
- Sleep scoring -- Five algorithms: Sadeh, Jean-Louis, Sazonov, Scripps, and threshold-based
- Periodogram analysis -- FFT and Lomb-Scargle (fast and exact implementations)
- Cosinor fitting -- Van Someren phase estimation with BCF/SBCF/BBCF/BSBCF models
- Detrended fluctuation analysis -- Fractal scaling of activity patterns
- Actogram plotting -- Double-plot actograms with configurable time axes
- Bout analysis -- Activity and rest bout duration distributions
% Run the command-line analysis on sample Vivago data
actiBox_cmdLine
% Or run the main program with GUI hooks
mainProgram_actiBoxConfiguration is centralized in setDefaultSettings.m -- adjust import format, computation flags, periodogram parameters, and plot options there.
MIT License. See LICENSE for details.