bioRxiv Science⌕ Search

bioRxiv · 10.64898/2026.03.24.713943

Event-Related Warping: A Toolbox for Temporal Alignment and Jitter Correction in Sequential Experimental Paradigms

Abstract

Sequential experimental paradigms are fundamental to cognitive neuroscience, yet standard event-related response analysis struggles with the temporal variability inherent to these designs. Conventional epoching treats each event within a sequence as an independent response, discarding the temporal dependencies between successive events and obscuring systematic changes in neural state that accumulate across the sequence. In order to generate responses that capture the entire sequence, it necessitates alignment across trials to correct for the inherent temporal jitter that would otherwise blur averaged responses and obscure the true sequential dynamics. Existing temporal alignment methods warp observed signals directly, making them vulnerable to correlated noise and potentially disrupting multichannel temporal relationships essential for connectivity and causal analyses. Event-Related Warping (ERW) addresses these limitations by aligning template functions encoding experimental event structure rather than neural signals themselves. Templates constructed from event onsets and durations undergo smooth monotonic warping via gradient-based optimisation, then estimated trajectories are applied uniformly across all channels, preserving inter-channel timing relationships and causal structure. This design-level alignment exploits experimentally observable jitter whilst maintaining signal integrity. Simulations with known ground truth incorporating Gaussian jitter, skewed latencies, amplitude-latency coupling, and multi-parameter dependencies yielded standardised root-mean-square errors (sRMSE) of 0.27-0.38. Distance-weighted averaging, emphasising temporally consistent trials, provided 5-13% improvement when jitter exceeded 100 ms, with maximal benefit ({approx}13% reduction) under quadratic amplitude-latency coupling. Empirical validation using an auditory go/no-go dataset with cue-to-target intervals of 1.5-4.1 seconds demonstrated that ERW recovers jittered target-locked responses with comparable fidelity (sRMSE 0.24-0.51) to conventional epoching of time-locked events, whilst preserving inter-channel lag relationships (cross-covariance sRMSE 0.63-0.82). ERW thus extends standard trial averaging to scenarios where temporal variability would otherwise preclude coherent response recovery, supporting investigation of temporally extended processing in ecologically valid paradigms whilst maintaining compatibility with established ERP frameworks and downstream connectivity analyses.

Explore related subjects

Keep this discovery

Explore connections, maps & timelines

BibTeXRIS

Levy, A., Zeidman, P., Friston, K.. 2026-03-26. Event-Related Warping: A Toolbox for Temporal Alignment and Jitter Correction in Sequential Experimental Paradigms. https://doi.org/10.64898/2026.03.24.713943

Cite the original work for its findings. Save a collection to share your selection of sources.

KEEP EXPLORING

Related preprints

Connexin 40 deficiency alters the temporal profile of postictal oxygen dynamics following focal seizures.

Epilepsy is increasingly recognized as a disorder involving both neuronal and vascular dysfunction. While connexin signaling has been implicated in epileptogenesis, the contribution of vascular connexins to seizure associated cerebrovascular pathology remains poorly understood. Connexin40 (Cx40) is an endothelial gap junction protein that plays a crucial role in vascular communication and blood-flow regulation. Seizures induce dynamic changes in cerebral perfusion and oxygenation, including prolonged postictal hypoperfusion/hypoxia. To determine whether Cx40 influences postictal hypoxia following focal seizures, we examined seizure characteristics and postictal oxygen dynamics in Cx40 knockout (Cx40-/-) mice using an established focal hippocampal seizure model. Electrically kindled seizures were elicited in wild-type and Cx40-/- mice, and local hippocampal tissue oxygenation was continuously monitored before and after seizure induction. Seizure duration did not differ between genotypes, indicating comparable seizure severity. Interestingly, Cx40 deletion altered the temporal pattern of postictal oxygen recovery, producing greater early hypoxia and a delayed secondary rebound in pO2 despite similar peak oxygen levels and overall hypoxic burden. These findings demonstrate that loss of Cx40 selectively alters the temporal profile of postictal oxygen dynamics without affecting seizure duration. Taken together, the results suggest that endothelial gap junctional communication contributes to postictal vascular recovery and identify Cx40 as a potential modulator of seizure associated neurovascular dysfunction.

neuroscience↗

Attention Across Scales: From Individual Variation to Social Hierarchies and Brain Networks in Semi-Free-Ranging Macaques

Attention is a fundamental brain function supporting perception, decision-making, and social behavior, and its dysfunction profoundly impairs daily life. It is both dynamic and stable, varying across observations and individuals, changing across the lifespan, and being shaped by social and environmental experience. Yet capturing this complexity remains a central challenge in neuroscience. Here, we integrated longitudinal behavioral assessments of semi-free-ranging macaques living in naturalistic social groups with resting-state fMRI. We quantified performance across days, ages, and social hierarchies and related it to intrinsic brain organization. Distinct attentional phenotypes emerged, including individuals with reduced attentional control. Performance followed an inverted-U lifespan trajectory, improving from childhood to adulthood before declining. Social status modulated attentional performance. Critically, nonlinear lifespan trajectories and associations with individual attentional differences were most clearly expressed in frontoparietal connectivity. Together, these findings reveal how sustained attention is organized across scales, providing a biological framework for its individual diversity, social modulation, and neural basis.

neuroscience↗

Decoding natural scenes from patterned optogenetic responses in mouse visual cortex

A central challenge in developing visual cortical prostheses is to determine how visual stimuli should be transformed into effective patterns of cortical stimulation. Although advances in stimulation technologies, including optogenetics, provide increasingly precise control over cortical activity, it remains unclear whether artificially evoked activity can reproduce the information content of naturally evoked visual representations. Here we establish a quantitative framework for evaluating visual encoding strategies by decoding cortical responses evoked by natural vision and patterned optogenetic stimulation. We developed a novel dual-modal paradigm in awake mice to bridge the gap between endogenous photostimulation and artificial network driving. By co-expressing the high-performance calcium indicator GCaMP6s and the red-shifted, ultra-sensitive opsin rsChRmine-oScarlet in the primary visual cortex (V1), we successfully translated dynamic natural movie frames into patterned, spatiotemporal optogenetic stimulation. Quantitative comparisons of macro-scale dynamics demonstrated that this patterned optogenetic injection evokes cortical states highly comparable and representationally aligned with those driven by actual visual photostimulation. To systematically evaluate the fidelity of these responses, we developed STAR, a deep learning model featuring spatial and temporal attention mechanisms, and successfully reconstructed the frames of natural movies from V1 signals under both experimental modalities. Collectively, our results demonstrate that complex sensory information can be both naturally encoded and synthetically injected into V1 circuits with high decoding fidelity. This work provides an empirical and computational proof-of-concept for intelligent, closed-loop biomimetic encoders, establishing a robust framework for next-generation cortical visual neuroprostheses and bidirectional brain-machine interfaces.

neuroscience↗