Time Series Variables
A time series variable records every value change during a trial, each paired with a timestamp. This is different from the default recording mode, which captures only the final value at the end of a trial.
Use time series variables whenever you need to track something that evolves continuously within a trial: gaze coordinates, mouse position, physiological signal values, or any response that changes over time rather than producing a single discrete outcome.
Setting Up a Time Series Variable
Time series recording is controlled by two variable properties:
- In the variable properties panel, set
Record TypetoAll changes / time series. This tells Labvanced to log each value change with a timestamp rather than waiting until the trial ends. - Make sure
Record Variableis enabled so the data is included in your export.
For variables that hold coordinates or arrays of values (such as gaze x/y), set Format to Array. For single continuous measurements (such as a slider position), Scalar is appropriate.
Sampling Method
When Record Type is set to All changes / time series, a Sampling method option appears in the variable properties panel. It controls how duplicate consecutive values are handled.
| Option | Description |
|---|---|
record changes only (no repeated duplicates) | Records a new data point only when the value changes. Consecutive duplicate values are skipped. |
record all (allow repeated duplicates) | Records a data point at every sample interval, including repeated values. |
The default depends on the variable format: scalar variables default to record changes only, and array variables default to record all. This matches the most common use pattern for each type.
Use record changes only when your variable updates infrequently and you want to minimize data volume. Use record all when you need a complete, evenly-spaced time series regardless of whether the value changes between samples, for example when sampling at a fixed interval via a loop.
How Time Series Data is Recorded
Each time the variable's value changes (or on every sample, depending on the sampling method), Labvanced stores:
- The variable value at that moment
- A timestamp relative to the trial
This produces one row per sample in the export, rather than one row per trial. Trials with many samples will produce many rows in the time series export.
Data Output
Time series variables are exported separately from regular trial-level data. In the Dataview & Export tab, there are two data downloads:
- Regular data: one row per trial, capturing final values of standard variables.
- Timeseries data: one row per recorded sample, with a timestamp column.
Within the timeseries export, you can choose to combine all time series variables into a single file (organized by time, alternating rows per variable) or export a separate file for each variable. A separate file per variable is easier to work with when variables have different sampling rates.
Common Use Cases
Mouse tracking: Record the mouse x/y position continuously during a trial by setting a numeric array variable to All changes / time series and using an event with a Mouse Move trigger to write the current position at each movement.
Eye tracking: Gaze coordinate variables created by the eye tracking system are time series by default. Each gaze sample is stored with its timestamp, allowing frame-by-frame analysis of fixations and scan paths.
Physiological signals: Variables receiving continuous physiological input (heart rate, head position) record as time series so the full signal is preserved across the trial duration.
Slider or continuous response: If a participant moves a slider throughout a trial and you want to capture the trajectory, not just the final position, set the linked variable to time series recording.