Skip to content

Methods

Frontiers in Organizational Psychology ·

Volume 4 - 2026 | https://doi.org/10.3389/forgp.2026.1892016

Capturing the rhythm of time: introducing Dynamic Time Warping in behavioral research

  • Juul Vossen1
  • Evy Kuijpers1*corresponding author
  • Joeri Hofmans1
  1. Work & Organizational Psychology, Faculty of Psychology and Educational Sciences, Vrije Universiteit Brussel, Brussels, Belgium
Article metrics0 viewsView details

Abstract

The growing use of high-intensity time series data has increased reliance on lag models to examine delayed effects. However, one key limitation of traditional fixed-lag models is their inability to flexibly account for variation in lagged effects within and across individuals. To address this, the current study introduces Dynamic Time Warping (DTW) as a technique that accommodates between- and within-person variation in the degree of temporal warping, defined as the extent to which time series need to be stretched or compressed in time to optimally align with each other. DTW is an algorithm that aligns two time series by flexibly stretching or compressing them to minimize their overall distance or mismatch. A key advantage of DTW is that it is model-agnostic, making it particularly suited for dealing with variation in temporal dynamics across diverse psychological processes—regardless of the underlying statistical model. To showcase its value, we compare DTW to DSEM in a simulated dataset, and to traditional lagged regression models in two Experience Sampling Method (ESM) datasets.

Keywords

Introduction

The analysis of time series data proves to be a valuable method for identifying dynamic patterns, and the incorporation of high-intensity time-series data in scientific research has experienced a noticeable surge over the past decade (Jebb and Tay, 2017; Kurbalija et al., 2012; Zhang et al., 2009). The realization that no theory might be truly time independent (Zaheer et al., 1999) has directed researchers to intensive longitudinal analyses because they allow exploring those temporal dependencies (Aguinis et al., 2009; Scandura and Williams, 2000). Although trend, seasonal, and cyclical components are key features of many phenomena (Jebb and Tay, 2017), another important characteristic is the dependency between prior states. It is therefore no surprise that lag models are widely used in time series studies to study delayed effects and to examine how past experiences affect concurrent and subsequent states (Kuiper and Ryan, 2020).

Yet, a common limitation of traditional lag models is that they assume the timing or onset of lag effects are identical across and within individuals, while this might not always be the case. People may exhibit variations in the timing and duration of psychological responses, and effects may differ between individuals and from one moment to the next (e.g., Hollenstein, 2015; Kuppens et al., 2010). Traditional fixed-lag models do not account for this, which is problematic because the statistical analysis of psychological processes should ideally align with a well-specified theory about their timing (Hopwood et al., 2022a; Mitchell and James, 2001).

To address this issue, the present study introduces Dynamic Time Warping (DTW) as a tool for aiding in the analysis of time-series data. DTW offers a promising solution, as it allows dealing with intra- and inter-individual differences in the timing of individual responses. It does so by using flexible temporal alignment (formally referred to as warping), allowing comparable observations (such as psychological states) to be matched even when they occur at slightly different moments in time. This allows DTW to capture both concurrent and delayed effects within the same analysis, providing a more accurate representation of individual temporal trajectories. To provide a proof-of-concept, we illustrate how DTW works in the context of contemporary time series modeling approaches by comparing the results of Dynamic Structural Equation Modeling (DSEM) with and without DTW using a simulated dataset, and by analyzing two Experience Sampling Method (ESM) datasets (Kuijpers et al., 2024) assessing concurrent and delayed effects of state conscientiousness on depletion. These ESM samples were chosen because prior work suggests that state (or counterdispositional) conscientiousness is linked to later levels of depletion (e.g., Kuijpers et al., 2024), allowing for explicit assumptions about the concurrent and delayed effects.

The limitations of traditional lag models

Time-series analysis has primarily been applied in fields such as stock market research, process and quality control. Later, these tools were adopted in behavioral sciences, and technological advancements have since driven further methodological innovations that support temporal research (Kurbalija et al., 2012). Although the behavioral sciences have generally been slower than, for example, the natural sciences in developing or adopting methods from other disciplines (Navarro et al., 2015; Vullinghs and Dóci, 2020), scholars have increasingly turned to time series analysis to explore the temporal patterns that shape psychological processes (Jebb et al., 2015). While there are practical challenges in collecting time series data (Jebb and Tay, 2017), the awareness that dynamic processes underlie human behavior has underscored the importance of analyzing patterns, trends, and fluctuations within specific timeframes. For example, the field of personality psychology has gradually shifted from a static view on personality to a dynamic perspective that considers both stability (i.e., traits) and change (i.e., states) (Sosnowska et al., 2019). As a result, ESM designs are now frequently used to collect high intensity time series data to capture fluctuating personality states (Sosnowska et al., 2021; Woods et al., 2019). Furthermore, continuous improvements in data collection techniques—including emerging technologies such as smartphones and wearable sensors—have made time series data increasingly accessible to researchers (Chaffin et al., 2017; Killingsworth and Gilbert, 2010).

The notable surge in high intensity timeseries data has increased our ability to detecting short-term changes, which helps explain why lag models are now widely used in time series studies. However, a key limitation of these models is that they assume that individual trajectories—the timing or onset of the lag effect—are identical across and within individuals, while this assumption might not hold in practice. For example, consider two hypothetical events in which an individual behaves more conscientiously than usual due to a complex task they must complete1. As shown in Figure 1, there can be substantial differences in the timing of the depletion effect across these two situations. In event one, the depleting effect of acting conscientiously emerges only at a later stage, whereas in the second event, the same behavior produces an immediate depletion effect. Even though the behavior may be identical across events, its impact may vary depending on contextual factors or participants' momentary state. For example, in the first event, the individual may begin with relatively low mental or physical fatigue, or perceive the situation as novel and adjust more gradually to task demands, leading to a delayed buildup of depletion. In contrast, in the second event, the individual may be more cognitively engaged, primed by prior experience, or already closer to depletion, causing the effect to appear immediately. In other words, while the first event is characterized by a delayed or lagged process, the second reflects a more concurrent process.

Example of two responses to conscientious behavior. Event one shows a delayed response of depletion, whereas event two shows a concurrent response of depletion.
Figure 1. Example of two responses to conscientious behavior. Event one shows a delayed response of depletion, whereas event two shows a concurrent response of depletion.

This illustrates that at different measurement moments, the same level of conscientious behavior can elicit different levels of depletion within an individual. Relatedly, differences in resilience may also give rise to between-person differences in how individuals respond to and recover from cognitive fatigue, with some people exhibiting greater resilience or recovering more quickly than others. These between-person differences may in turn also vary across measurement moments (e.g., a person's resilience may be lower early in the morning after a bad night's sleep) (Hagger et al., 2010). A similar dynamic can be observed in workplace interactions involving emotional labor: employees may differ in how quickly and intensely they experience strain when regulating their emotions toward customers or colleagues, reflecting individual differences in emotional intelligence and reactivity (Brackett and Mayer, 2003). Employees may also adapt at varying rates to new teams or supervisors, with some synchronizing quickly with their manager's communication style, and others adjusting more gradually over time.

From an analytic perspective it is challenging to deal with such differential processes. For instance, a common approach to studying lagged effects—shifting one of the focal variables to match past observations to match past to subsequent observations—may improve the alignment between the variables for event two in our example, but this same lag specification will worsen the alignment for event one. As such, we need an approach that accounts for concurrent effects while simultaneously applying lags of variable sizes for instances for which there is a delayed effect.

The basic premises of the DTW algorithm

One technique that allows accommodating for differences in the timing of effects is DTW. As early as 1971, Hiroaki Sakoe and Seibi Chiba introduced time warping as a technique that was particularly useful for comparing time series data where the sequences might have temporal distortions, shifts, or variations in length. The idea was to compare two trajectories that are not only subjected to alteration by random error but also to variations in speed (Sankoff and Kruskal, 1983; Di Brina et al., 2008). Functional data analysis provides a useful illustration: children's growth curves generally follow the same overall shape, but differ in the timing of key developmental features (Ramsay and Silverman, 2005). That is children's height trajectories typically show steady growth, a pubertal growth spurt, and an eventual plateau, but the timing of the growth spurt varies substantially across children. Comparing height at the same chronological age therefore suggests large differences, even though the underlying developmental process is essentially the same. Time warping addresses this by stretching or compressing the time axis so that comparable features, such as the onset of the growth spurt, are aligned, revealing the shared trajectory despite differences in timing. To facilitate interpretation, Table 1 provides psychologically meaningful descriptions of the formal DTW terminology used throughout the chapter.

Table 1. Key DTW concepts translated into psychologically meaningful terms.

Formal DTW/mathematical termPsychologically meaningful translationWording
(Local) cost/distance(Momentary) mismatchCost and distance refer to the same underlying concept: the mismatch between observations. Distance is typically used to describe the raw difference between two values (e.g., Euclidean distance), whereas cost refers to how these mismatches are incorporated within the DTW algorithm
Cost matrixMap of all possible mismatchesThe cost matrix contains the mismatch for every possible pairing of observations from the two variables
WarpingTemporal alignmentWarping allows comparable observations (e.g., psychological states) to be matched even when they occur at slightly different moments
Warping pathAlignment trajectoryThe warping path shows how observations from the two time series are matched over time
WindowAllowed time shiftThe window constrains how far apart in time two observations may be matched”
Step functionAlignment ruleThe step function determines how the algorithm is allowed to move through the two time series

DTW is a specific class of algorithms that operationalizes the idea of time warping and is designed to minimize the distance or mismatch between two time series. The underlying assumption is that both time series are essentially similar in shape, but that their time scales have been altered by a non-linear transformation. An intuitive example that helps convey this notion of non-linear transformation can be found in the context of stress responses. Consider two employees facing a similar high-pressure deadline with both showing increase in stress levels and coping behaviors, but the pace at which these responses unfold can differ. One employee's stress might rise sharply and subside quickly after using coping strategies, while another's stress might build more slowly and linger longer. DTW aims to minimize the (Euclidean) distance between these two time series by flexibly compressing and stretching the time axis so that comparable patterns—such as peaks in stress or dips in coping resources—become more aligned, even when they occur at different moments or unfold at different rates.

To illustrate how minimizing the Euclidean distance between two sets of observation affects the strength of the association between two variables, it is useful to consider the correlation as a function of the Euclidean distance between the standardized co-occurrences (see Equation 1). Specifically, the correlation between X and Y can be expressed as:

r(X,Y)=1- 1n∑i=0n(xi- yi)22n(1)

where X and Y are standardized and therefore on the same scale. According to this formula, as the Euclidean distance (the numerator) between X and Y gets closer to 0, the correlation approaches 1. To find the optimal alignment and minimize the distance or mismatch, DTW first computes a cost matrix—a map of all possible mismatches between two time series (Giorgino, 2009). Each cell in this matrix represents the moment-to-moment mismatch associated with pairing a specific observation from one time series with a specific observation from the other. In DTW terminology, this mismatch is referred to as the local cost or distance2. The more dissimilar the two observations (e.g., psychological states) are at a given pairing, the higher the cost. DTW then uses dynamic programming to identify the path through this matrix that minimizes the total cumulative cost. As the algorithm traverses the matrix, each step adds the mismatch at that pairing to a running total, and the path with the lowest cumulative cost is selected as the optimal alignment.

To ensure that the flexible temporal alignment (i.e., warping) performed by the algorithm aligns with theoretical expectations, different constraints can be imposed on the algorithm. Common constraints include requiring that the first and the last observation in the warped path correspond to the first and the last observation of the two timeseries, and that the cost function of the warped path is monotonically increasing. This means that the path cannot move backward in time or loop to minimize the cost or mismatches, it must respect the ordered nature of the time variable. Given the relevance of DTW in our field of research3, we focus on three additional key constraints: the step function (i.e., the alignment rule determining how the algorithm moves through the two time series), the window type (i.e., the direction of allowed temporal shifts), and the window size (the maximum number of timepoints -or allowed time shift- over which observations can be matched).

Symmetric and asymmetric step functions

When using DTW, aligning two timeseries is generally achieved by allowing observations in series to match multiple (consecutive) observations in the other series, and vice versa. This involves either skipping observations or matching consecutive ones. The number of observations that can be skipped or consecutively matched is controlled by the step function. The step function defines the alignment rules that determine how the algorithm is allowed to move through the two time series. Essentially, there are two main types of step functions: asymmetric and symmetric. With an asymmetric step function, the time scale of one series (i.e., the template) is transformed to match the time scale of the other (i.e., the query). In this case, we usually refer to a query and a template, where the template is warped to align with the query4. With a symmetric step function, the time scale of both timeseries are transformed to fit a common time scale. In other words, while the asymmetric step function stretches and compresses one timeseries to match the other's original time scale, a symmetric step function stretches and compresses both series simultaneously to achieve optimal alignment (Sakoe and Chiba, 1971).

While symmetric step functions have been shown to be superior with respect to speech recognition (Sankoff and Kruskal, 1983; Sheuli, 2007), both approaches have their advantages and disadvantages when applied to I-O and organizational behavior research. Specifically, the symmetric step function has the main advantage that all observations are used in the matching process, while the asymmetric step function, only the observations of query (i.e., the timeseries that is held constant). This indicates that for the asymmetrical step function, the observations in the template signal (i.e., the timeseries that is transformed) may be omitted entirely if an observation is sub-optimal to its neighbors in a given time-window. In other words, strong outliers are more likely to be omitted and replaced by less extreme neighboring values. While a symmetric step function does not explicitly omit extreme values, it produces a similar regularizing effect: better fitting values are stretched out (i.e., duplicated), resulting in their higher representation in the transformed dataset compared to outliers. The downside of the symmetric step function, however, is that we lose interpretability, as both time dimensions are stretched. Specifically, implementing DTW at the individual level, we will likely obtain different time scale lengths for each individual, which complicates the interpretation at the between-person level. In the illustrative example of the current paper, an asymmetric step function is used, as having a fixed reference time scale allows us to compute the lag of each observation with respect to the original timescale. In our case, this means that we can evaluate for each individual and each measurement moment where the depletion effect occurs relative to when that person acts more conscientiously (see also Figure 1). Having the lag of each observation at the individual level provides a wealth of information about the dynamical nature of the relationship between the two timeseries. First, it allows inspecting the individual differences in the degree of flexible temporal alignment or warping (i.e., occurrence of lagged effects). Second, it opens the possibility to test warping-based hypotheses, such as whether certain situations elicit stronger concurrent effects or more pronounced delayed effects.

Window size and type

A second important constraint is the size and type of the window, which can also be referred to as the maximum allowed time shift. The size of the window refers to the number of lagged observations that is taken into account by the algorithm. In other words, the window size determines how far apart in time two observations may be matched. For instance, when we allow for a lag of two measurement moments, the algorithm will minimize the cost or mismatches by considering observations that are up to two timepoints away from the current timepoint. The type of window refers to the directionality of the matching—that is, which observations within the window are considered at each step. Figure 2 illustrates two time series with 10 observations each, using a window size of one. The panels differ in the direction of the allowed steps. Looking from the perspective of the query timeseries (i.e., the timeseries that is held constant), the algorithm is allowed to match query 1 to reference 2, match query 2 to reference 1, or match query 2 to reference 2. For example, if we expected the predictor (i.e., conscientious behavior) to have a delayed effect on the outcome (i.e., depletion), only forward steps should be allowed. However, when the query variable can both influence and be influenced by the reference variable, a window type that considers both future and past reference points is needed—as shown by the left-hand panel of Figure 2.

Two types of window types of size one with **(A)** considering bi-directional steps, and **(B)** only forward steps (with respect to the query variable).
Figure 2. Two types of window types of size one with (A) considering bi-directional steps, and (B) only forward steps (with respect to the query variable).

To summarize, the DTW algorithm operates by minimizing the distance or overall mismatch between two time series while respecting a predefined set of constraints. Importantly, DTW is not a statistical model, but rather a data preprocessing technique—comparable to steps such as data imputation or z-score standardization. Rather than estimating statistical parameters or model fit indices, DTW identifies an optimal alignment trajectory, formally referred to as the warping path, that minimizes the distance or overall mismatch between two time series under the specified constraints. This alignment trajectory specifies how observations from the two time series are matched across time. Measures such as explained variance or model fit can therefore only be evaluated after the aligned time series have been entered into a separate statistical model. Accordingly, DTW is applied prior to any statistical modeling and does not make assumptions about the distribution of the data. As such, DTW serves to align time series in a way that captures individual differences in temporal dynamics, after which researchers are free to apply any statistical model of their choice (e.g., multilevel modeling, regression, structural equation modeling). As a result, considerations related to sample size or model complexity pertain not to the DTW procedure itself, but to the statistical modeling approach that is used subsequently. This distinction highlights DTW's flexibility: it complements, rather than replaces, conventional modeling pipelines. To facilitate the application of the proposed DTW methodology, we provide a decision flowchart (see Figure 3).

Decision flowchart for determining when and how to apply DTW.
Figure 3. Decision flowchart for determining when and how to apply DTW.

Aligning the DTW model constrains with theory

As with all approaches in psychology—and scientific research in general—it is essential that choices regarding the algorithm constraints are guided by theory (see also Hopwood et al., 2022b). This is particularly critical because the primary goal of the DTW algorithm is to minimize the Euclidean distance between two time series. As such, DTW will never decrease model fit, which can only improve or remain the same. Consequently, the interpretation of results must always consider the theoretical rationale behind the chosen constraints, as these decisions shape how the algorithm represents the underlying process.

To illustrate how the algorithm works, we refer to the previous example shown in Figure 1. In Figures 4, 5 the DTW algorithm is applied to event one and two respectively, using only forward matching and a window (i.e., a maximum allowed time shift) size of 30. In the bottom panels, the color gradient represents the cumulative cost at each cell of the cost matrix. Yellow indicates a low cumulative cost, meaning that the cell lies on or near an optimal alignment, whereas dark red indicates a high cumulative cost and therefore a less optimal alignment. Importantly, the colors reflect the cumulative alignment cost rather than the degree of stretching or compression. Stretching and compression are instead indicated by the shape of the optimal warping path (solid line): diagonal segments represent one-to-one matches, whereas horizontal or vertical segments indicate that one observation is matched to multiple observations in the other time series. Thus, the figures illustrate how the warping path transforms the initial Euclidean alignment into a lower-cost warped alignment by allowing observations from the independent variable to be matched with temporally shifted observations from the dependent variable. Figure 6 highlights the true flexibility of DTW by running the algorithm on the combined time series of event one and two. Specifically, this figure showcases two key features of the algorithm. First, the optimal warped path for the combined events closely resembles the combination of the optimal paths identified for each event separately. This indicates that the algorithm can simultaneously accommodate both concurrent and lagged effects. Second, it shows that the processing of the different types of effects occurs independently; the larger window size needed to optimize event one does not interfere with the temporal alignment or warping for event two. In other words, optimization is primarily driven by the local cost and the algorithm adjusts only where this leads to a better fit. Finally, Figure 7 demonstrates that implementing DTW on both individual and combined events substantially increases the explained variance by building on concurrent effects and incorporating lagged effects where necessary.

Distance matching with and without DTW for Event 1. The top image shows the normal Euclidean distance and the warped distance with an only forward relationship and a window size of 30. The bottom images show the cost function where darker values indicate paths with higher cost. The algorithm only considers the colored cell when finding the optimal paths.
Figure 4. Distance matching with and without DTW for Event 1. The top image shows the normal Euclidean distance and the warped distance with an only forward relationship and a window size of 30. The bottom images show the cost function where darker values indicate paths with higher cost. The algorithm only considers the colored cell when finding the optimal paths.
Distance matching with and without DTW for Event 2. The top images show the normal Euclidean distance and the warped distance with an only forward relationship and a window size of 30. The bottom images show the cost function where darker values indicate paths with higher costs. The algorithm only considers the colored cell when finding the optimal paths.
Figure 5. Distance matching with and without DTW for Event 2. The top images show the normal Euclidean distance and the warped distance with an only forward relationship and a window size of 30. The bottom images show the cost function where darker values indicate paths with higher costs. The algorithm only considers the colored cell when finding the optimal paths.
Distance matching with and without DTW for the combination of Event 1 and 2. The top image show the normal Euclidean distance and the warped distance with an only forward relationship and a window size of 30. The bottom images show the cost function where darker values indicate paths with higher cost. The algorithm only considers the colored cell when finding the optimal paths.
Figure 6. Distance matching with and without DTW for the combination of Event 1 and 2. The top image show the normal Euclidean distance and the warped distance with an only forward relationship and a window size of 30. The bottom images show the cost function where darker values indicate paths with higher cost. The algorithm only considers the colored cell when finding the optimal paths.
Effect of DTW using the same time lag as specified in Figure 1. Left *R*<sup>2</sup> values represent the fit between unwarped observations. Right *R*<sup>2</sup> values represent the fit between the warped observations.
Figure 7. Effect of DTW using the same time lag as specified in Figure 1. Left R2 values represent the fit between unwarped observations. Right R2 values represent the fit between the warped observations.

Positioning DTW within contemporary time series modeling approaches

A range of modeling approaches exist that capture temporal dependencies and lagged effects, including DSEM, Vector Autoregressive (VAR) models, and Hierarchical Linear Models (HLM). These techniques typically rely on explicit assumptions about lag structures and often require complex parameter estimation and imputation procedures. In contrast, DTW offers a flexible, model-agnostic alternative that aligns observed time series based on actual data patterns rather than predefined parameters. This makes DTW especially well-suited for analyzing the timing and duration differences across individuals. In what follows, we position DTW in relation to these more conventional approaches by examining its parameter estimation strategy, flexibility in lag structure, treatment of temporal dependencies, and approach to missing data.

Parameter estimation

Whereas conventional approaches require explicit specification of lag parameters and often involve estimating a large number of parameters, DTW is a model-agnostic technique. It can therefore be applied flexibly across diverse research questions and statistical frameworks without relying on strong parametric assumptions or predefined lag structures. DTW therefore offers a complementary alternative to traditional models, and rather than estimating parameters for each lag, DTW aligns observed time series by aligning the temporal dimension, allowing researchers to detect intra- and inter-individual differences in timing and duration directly from the observed data. This avoids the complexity of extensive parameter estimation, instead focusing on matching actual observed patterns.

Fixed lag structures

Traditional approaches typically specify—often up to three—fixed time lags, assuming that lagged effects occur at regular intervals within the individual and applying the same lag structure across individuals5. This uniformity may not reflect true variation in the timing of effects. DTW, instead, does not require pre-specifying fixed lags but identifies the optimal temporal alignment between two variables, even when the delay or timescale varies within and between individuals. Rather than imposing a one-size-fits-all lag structure, DTW adapts to the observed data within a defined time window, offering a more flexible approach. A related family of approaches, continuous time structural equation models (CTSEM; Voelkle et al., 2012; Driver et al., 2017; Driver and Voelkle, 2018), sidesteps the fixed-lag problem by modeling observed measurements as discrete realizations of an underlying continuous-time process via differential equations. This makes CTSEM particularly well-suited for unequally spaced measurements. Like DSEM and VAR, however, CTSEM remains parametric: it estimates drift and diffusion parameters under a specified structural form and typically assumes stationarity of the underlying process. Random effects can capture between-person differences in the magnitude of these parameters, but the functional form of the process is still imposed uniformly across individuals. DTW differs in that it makes no parametric assumptions about the generating process and explicitly allows the temporal alignment itself to vary across individuals, capturing differences not only in the strength but also in the timing of effects.

Temporal dependencies

Relatedly, some approaches have addressed temporal dependencies by modeling the structure of residual errors, particularly when they have explicit assumptions about autoregressive effects. For instance, the nlme package in R (Bates et al., 2015) allows for the specification of an autoregressive error structure, assuming that correlations between observations decay at a fixed rate over time. While this method can effectively model lagged effects via structured residuals, it typically assumes equally spaced measurements and applies a uniform decay rate. In contrast, DTW does not rely on predefined decay patterns or distributional assumptions, and instead flexibly identifies variable lags without the need for formal error modeling.

Handling missing data

Missing observations are common in intensive longitudinal studies and represent an important methodological consideration when estimating dynamic effects. Traditional time-series approaches, such as Vector Autoregression (VAR), are often estimated using methods such as Ordinary Least Squares (OLS), where missing observations may lead to listwise deletion and potential bias when data are not missing completely at random. Modern likelihood-based approaches, however, can accommodate missing data under the assumption of missing at random (MAR) through individual likelihood-based estimation (Little and Rubin, 2002). Similarly, Bayesian approaches such as DSEM can directly incorporate incomplete observations during estimation under MAR assumptions (Asparouhov et al., 2018). Nevertheless, many time-series applications still require careful handling of missing observations, and researchers may have to rely on imputation methods [e.g., (MICE; Van Buuren and Groothuis-Oudshoorn, 2011)] to create complete datasets before analysis. Thus, handling missing observations remains an important challenge in intensive longitudinal research, particularly when missingness is extensive, systematic, or when MAR assumptions may not hold.

In contrast, DSEM can accommodate incomplete data via Bayesian estimation. In Mplus, missing values are treated as unknown parameters and imputed conditionally on neighboring observations, their dynamic relationships (autoregressive and cross-lagged effects), and residual uncertainty, under the assumption of missing at random (Fang and Wang, 2024; McNeish and Hamaker, 2020). This approach allows participants with partially missing time series to contribute to parameter estimation. However, this can reduce the precision of both intra-individual and between-person parameters (Black et al., 2012; Ji et al., 2018), making missing data a significant challenge when applying DSEM to real data (Asparouhov and Muthén, 2022). DTW, on the other hand, does not require complete data. Missing observations are simply excluded during the alignment process, meaning that only the available data points are matched directly without the need for prior imputation. While optional imputation methods can be applied to reduce the number of missing values, they are not necessary for the algorithm to function. DTW therefore maximizes the use of available observations.

The current study: illustrative examples

In the present study, we aim to test the ability of DTW to accommodate complex temporal dynamic in time series data. First, to compare DTW to contemporary time modeling techniques, we apply both DTW and DSEM to a simulated dataset. Second, to demonstrate the practical utility of DTW for real-life data, we apply the algorithm to two ESM datasets, testing whether conscientiousness-related behavior may lead to later levels of depletion (see Kuijpers et al., 2024) In this application, DTW is performed within individuals and across constructs: each individual's state conscientiousness time series is aligned with their own depletion time series to identify person-specific temporal dynamics6. The idea is that people typically display high levels of conscientiousness by working in a productive, responsible, and industrious manner, and over time, such resource-demanding behaviors may cause (accumulated) depletion (Kuijpers et al., 2024). As such, an asymmetric step function and a directional window type is specified where state conscientiousness is allowed to match concurrent or subsequent depletion. Moreover, because there are also reasons to expect that people fail to act in a conscientious manner when they are depleted, an exploratory analyses will allow for bi-directional steps in which conscientiousness is allowed to match both future and past observations of depletion. With respect to the window size, we impose an additional constraint that refers to the day of the measurement. That is, our initial model will only allow align or warp between observations within the same day, while in an exploratory model we will permit warping between observations from both the same day and the previous day. Consequently, we arrive at the following hypotheses:

  • Hypothesis 1. The relationship between state conscientiousness and depletion is characterized by both concurrent and lagged effects. Incorporating concurrent and lagged effects using the DTW algorithm increases the model fit to the data over and above the model without DTW.
  • Hypothesis 2. Individuals differ in the extent to which the relationship between state conscientiousness and depletion is driven by concurrent or lagged effects.

Furthermore, to facilitate the application of DTW in psychological research, we developed an interactive Shiny application that allows users to explore how different DTW settings influence the resulting temporal alignment between time series. Users can work with the provided example data and specify key DTW parameters—including the step pattern, window type, and window size—to examine how these choices affect the warping path and the resulting alignment. The application provides visualizations of the aligned time series together with the corresponding warping path, allowing users to inspect how observations across the two series are aligned under different parameter settings. By providing an interactive interface, the application enables researchers to explore the behavior of DTW without requiring programming experience. The Shiny application is freely available at https://juulvossen.shinyapps.io/DTW_app/.

Study 1

Materials and equipment

All analyses were carried out using R and Mplus version 8.4 (Muthén and Muthén, 1998-2017). Data simulation and DTW computations were performed in R using the dtw package (Giorgino, 2009). DSEM was conducted in Mplus 8.4 using its Bayesian estimator (McNeish, 2019). No additional materials or equipment beyond standard computing infrastructure were required. Data and analysis script used for this article can be accessed at https://osf.io/a96st/?view_only=bfabcc5578c6405c9d62f24a891dc237.

Methods

Simulated dataset

To compare the DTW approach to DSEM, we generated data using the following approach. First, we created a single activation event by taking a simple sine wave and adding the absolute value of the minimum value to the overall function. In essence, what this does is raise the minimum value to 0 and the maximum value to 2. We then take a slice of this function to get a single activation that is preceded and followed by five instances of zero. For the X time series, we simply repeat this pattern so we have evenly spaced activations. For the Y time series, we take two consecutive activations and shift the leading zeroes of activation one, and the trailing zeros of activation two in between the two activations. In other words, we move all the zeros in between the two activations, which causes the first activation to occur earlier than the reference signal, and the second activation to occur later than the reference signal (i.e., within-person variation in the lags; see Figure 8). This pattern is then repeated to match the length of the reference signal.

Illustration of the simulated patterns.
Figure 8. Illustration of the simulated patterns.

To introduce inter-individual differences in the lags, we randomly sampled 100 slices of 100 timepoints each at different locations in the signals, with each slice representing one simulated participant, yielding a simulated sample of N = 100 participants. This gives us subsections of the data with different starting points, and different prevalences of the activation functions. Specifically, slices of 100 timepoints always yield three activations, meaning that there are either always two lags vs. one lead relations or vice versa. Figure 9 illustrates this process for nine simulated individuals. Each panel shows a 100-timepoint segment randomly sampled from the same underlying pair of periodic signals. The blue signal (Y) follows a constant periodic activation pattern, whereas the red signal (X) alternates between leading and lagging Y. Because the segments are sampled from different starting points in the underlying signals, individuals differ in the observed timing of the activations and in the prevalence of lead vs. lag relations within the sampled interval. Specifically, each 100-timepoint segment contains three activations, resulting in either two lead and one lag relation or two lag and one lead relation. Finally, we created a dataset with missing values to reflect a more realistic scenario and to examine how the results change given that the analytical approaches handle missing data differently. Missingness was generated under a missing at random (MAR) mechanism, such that the probability of a missing observation depended on previously observed values.

Illustration of signal slicing procedure used to introduce inter-individual differences in lag. Each panel represents one simulated individual. Note. This figure provides a simplified illustration of how local discrepancies between two time series contribute to the DTW distance. The pronounced discrepancies at the beginning and end of the series are deliberately exaggerated for illustrative purposes and are not intended to represent the typical structure of the empirical ESM trajectories.
Figure 9. Illustration of signal slicing procedure used to introduce inter-individual differences in lag. Each panel represents one simulated individual. Note. This figure provides a simplified illustration of how local discrepancies between two time series contribute to the DTW distance. The pronounced discrepancies at the beginning and end of the series are deliberately exaggerated for illustrative purposes and are not intended to represent the typical structure of the empirical ESM trajectories.

Analysis plan

DSEM: We performed DSEM analyses in Mplus 8.4 (McNeish, 2019). A core characteristic of DSEM is that it allows for the simultaneous estimation of within-person lagged effects and between-person differences in those effects via random slopes. DSEM also accommodates latent variable modeling, enabling users to examine the dynamics of unobserved constructs over time while accounting for measurement error. Finally, DSEM allows modeling longitudinal data where participants may have differing numbers of time points or observations at irregular times. These issues can be accounted for by specifying the TINTERVAL statement in Mplus, which specifies the time grid for the analysis. In particular, it divides the timeline into sequential, equal-length periods, assigns each observation to a time period, and inserts missing data for any periods in which no observation(s) was obtained, creating a dataset with consistent time intervals across participants. This approach ensures that all available observations can be included in the model, while still allowing for meaningful interpretations of lagged effects (McNeish and Hamaker, 2020). In our analysis, we used a minimum of 2,000 iterations, non-informative priors, and a thinning parameter of 5. Further details on model specification, convergence, computation time, etc., can be found on the OSF page.

DTW: Because the DTW algorithm aligns two time series by minimizing the distance between their signals, it is essential that both signals are on the same scale for the alignment to work properly. Therefore, we used within-person z-score standardization for both the independent (i.e., X) and the dependent (i.e., Y) time series, ensuring that the predictor and outcome are expressed in comparable units and have a shared interpretation. By standardizing the variables, we focus on within-person deviations from individuals' average levels—so that the distances between observations reflect meaningful covariation, rather than being confounded by differences in individuals' overall mean scores on the respective scales.

Furthermore, for DTW it is important to ensure that the relationship between the two variables operates in the same direction. Specifically, when the variables are strongly negatively correlated—such that positive deviations in one variable correspond to negative deviations in the other variable, or vice versa—it is necessary to invert one of the variables (i.e., multiply by −1) prior to applying the warping procedure. Failing to do so would lead the algorithm to minimize distances that are primarily driven by the inverse association, thereby obscuring the meaningful temporal alignment between the signals.

We performed DTW on each ”individual” using the dtw package (Giorgino, 2009) in R studio under various configurations as a preprocessing step. Specifically, we used the asymmetric step function to warp X while keeping the time-scale of Y fixed, and compared an only forward matching (i.e., X may only warp with Y at later timepoints) and forward and backward matching (i.e., X may warp to Y at previous and later timepoints) within a time window of 1, 2, and 3 lags. The warped X, and Y variables for each “individual” are then provided as input for linear mixed effects models using the lme4 package (Bates et al., 2015).

Results

Dataset without missings

When predicting Y with progressively adding up to three time lags using DSEM, we find that the model with three lags has a better model fit (lowest DIC) and the highest explained variance (R2 = 0.64) than the models with two and one time lag. In this model, all lagged effects significantly predict the dependent variable except for the second lag (see Table 2). When comparing these results with the results of the DTW analysis, in which only a forward window up to three lags is allowed (see Table 3), we found that both approaches agree on the broader conclusion that model fit and explained variance improve as more lags/warps are allowed (R2 = 0.54). Notably, when restricted to forward-looking effects only, DSEM (three lags, R2 = 0.64) fit the data somewhat better than the forward-only DTW model (window = 3, R2 = 0.54).

Table 2. DSEM analysis predicting Y and from X, concurrent and delayed effects—data without missings.

VariablesModel 0Model: lag 1Model: lag 2Model: lag 3
Est95% CIpEst95% CIpEst95% CIpEst95% CIp
Fixed effects
Y (int)1.71[1.69;1.72]< 0.011.70[1.69;1.72]< 0.011.70[1.69;1.71]< 0.011.70[1.69; 1.72]< 0.01
X0.57[0.56;0.59]< 0.010.41[0.24;0.58]< 0.010.60[0.44;0.81]< 0.010.96[0.83; 1.12]< 0.01
X_lag1–––0.17[−0.00;0.35]0.03−0.27[−0.60; −0.05]< 0.01−0.70[−0.90; −0.51]< 0.01
X_lag2––––––0.26[0.14;0.43]< 0.010.00[−0.14; 0.14]0.48
X_lag3–––––––––0.35[0.27; 0.45]< 0.01
Random effects
Residual within (σ2)0.38[0.37;0.39]–0.36[0.35;0.37]< 0.010.36[0.35;0.37]< 0.010.355[0.346; 0.365]< 0.01
Intercept between (τ00)0.001[0.001;0.002]–0.001[0.001;002]< 0.010.001[0.001;002]< 0.010.001[0.001; 0.002]< 0.01
X concurrent–––0.68[0.49;95]< 0.010.38[0.19;0.60]< 0.010.209[0.111; 0.348]< 0.01
X_lag1–––0.71[0.51;1.00]< 0.010.22[0.04;0.43]< 0.010.151[0.032; 0.347]< 0.01
X_lag2––––––0.09[0.03;0.19]< 0.010.058[0.014; 0.146]< 0.01
X_lag3–––––––––0.043[0.017; 0.089]< 0.01
Model information
Obs10100––10100–––10100–10100––
R20.33––0.49–––0.61–0.64––
DIC18868.001––18457.783–––18444.849–18348.1––

Table 3. DTW analysis predicting Y from X, with forward window specification 0, 1, 2, and 3—data without missings.

VariableWindow = 0Window = 1Window = 2Window = 3
EstCIpEstCIpEstCIpEstCIp
Y (int)0.74[0.71; 0.77]< 0.010.62[0.59; 0.65]< 0.010.52[0.49; 0.55]< 0.010.44[0.42; 0.47]< 0.01
X0.57[0.55; 0.59]< 0.01–––––––––
X Warped–––0.64[0.63; 0.66]< 0.010.71[0.69; 0.72]< 0.010.75[0.74; 0.77]< 0.01
Obs10100101001010010100
R2/R2 adj.0.326/0.3260.405/0.4050.477/0.4770.535/0.535
AIC18830.69017575.80116259.76915083.316

Est, estimator; CI, confidence interval; Obs, observations.

Notably, when further inspecting the results of the DSEM model, the estimated effect of the first lag changed direction depending on model specification: it was positive in Models 0 and 1, where only the concurrent association and one lagged effect were estimated, but became negative in Models 2 and 3, where additional lags were included. This sign reversal across lags is a common feature of distributed-lag models such as this one: because the three time lags of X are entered simultaneously as separate predictors in the same equation, and X is autocorrelated over time, each lag's coefficient reflects its unique contribution net of the (overlapping) other lags. This can produce unstable or sign-reversing coefficients across lags even when the underlying association between X and Y is monotonic (Basagaña and Barrera-Gómez, 2022). In contrast, the DTW coefficients are positive across all window sizes and increase steadily in magnitude, rather than changing sign across lags (see Table 3). This difference arises because DTW does not enter each lag as a separate, competing predictor: within a given window, the warping algorithm identifies, per observation, the single best-aligned time point, and only one “X Warped” term is estimated for that window. This coefficient therefore reflects a marginal, summary association rather than a partial effect estimated net of correlated neighboring lags, and is consequently not directly comparable to the individual DSEM lag coefficients—even though both approaches converge on the same overall conclusion that fit and explained variance improve with additional lags/warps. From a practical standpoint, this may also make the DTW coefficients somewhat more straightforward to interpret than the DSEM lag coefficients, for which sign reversals across lags can complicate interpretation.

Finally, the random slopes have a different interpretation in the DSEM (or fixed-lag) models than in the DTW models. In the DSEM models, the random slope variance for X reflects between-person differences in the strength of the association at a single, fixed lag. Because this lag is imposed on all individuals, the estimated slope variance may partly reflect differences in how well the chosen lag matches each individual's underlying temporal dynamics. In the DTW models, by contrast, the temporal alignment between X and Y is first optimized separately for each individual. As a result, the remaining random slope variance primarily reflects between-person differences in the strength of the association between the warped parameter and outcome rather than variability arising from a common fixed lag that does bit fit each individual's temporal alignment equally well7.

A unique benefit of the DTW approach, however, is that the user can also allow both forward and backward warps. As can be seen from Table 4, the model in which a window up to three warps is allowed in both directions, yields the best fit—with an AIC value of 5107.310 and R2 of 0.83. These individual warping paths or aligning trajectories can also be plotted, which is illustrated in Study 2 (“Exploring individual differences in lagged effects”). Because the simulated data explicitly contained both lagged and leading relations (two lags vs. one lead), the true underlying structure is inherently bidirectional. While DSEM and DTW with only forward warping capture parts of this dependency structure, only the DTW approach allowing both forward and backward warps successfully reflects the true underlying dependency structure. This indicates that by allowing both forward and backward warps, the DTW approach explains more variance, offers a better fit with theoretical predictions about bidirectional lagged effects, and more closely approximates the data-generating process.

Table 4. DTW analysis predicting Y from X, with forward and backward window specifications 0, 1, 2, and 3—data without missings.

VariableWindow = 0Window = 1Window = 2Window = 3
Est.CIpEst.CIpEst.CIpEst.CIp
Y (Int)0.74[0.71; 0.77]< 0.010.49[0.47; 0.52]< 0.010.29[0.27; 0.32]< 0.010.15[0.13; 0.16]< 0.01
X0.57[0.55; 0.59]< 0.01–––––––––
X Warped–––0.72[0.71; 0.73]< 0.010.83[0.82; 0.85]< 0.010.92[0.91; 0.93]< 0.01
Obs10100101001010010100
R2/R2 adj.0.326/0.3260.499/0.4990.676/0.6760.827/0.827
AIC18830.69015839.07611429.2505107.310

Finally, the warped data obtained from DTW can also be used in Mplus when conducting DSEM. Warped data refer to the individually time-aligned version of the original time series obtained by applying the DTW alignment path as a preprocessing step. Specifically, observations are repositioned according to the estimated temporal correspondence between both time series, resulting in a re-indexed dataset that retains the original long-format structure while reflecting the individualized temporal alignment. This illustrates that DTW is complementary to other statistical approaches and can be integrated with them. As shown in Table 5, the model incorporating concurrent effects using the warped data demonstrates superior fit, with the lowest DIC, and substantially higher explained variance (R2 = 0.83) compared to the model without warped data (Table 5). This suggests that aligning the time series via DTW can enhance the predictive power of the model. This approach should, however, be interpreted with caution. Because the DTW alignment is estimated before the DSEM model is fitted, the resulting effects reflect the combined influence of both the alignment procedure and the statistical model rather than either component in isolation. Consequently, the model no longer operates on the original clock-time scale but on an aligned (or warped) time scale, meaning that estimated lagged effects represent associations between temporally corresponding positions in the aligned trajectories rather than effects occurring after a fixed number of measurement occasions. We therefore present this analysis as an exploratory illustration of how DTW-aligned data can be integrated into existing modeling frameworks, rather than as a confirmatory estimate of the timing of the underlying processes.

Table 5. DSEM analysis using unwarped and warped data–without missings.

VariableWindow = 0Window = 3 (Forward and Backwards)
EstCIpEstCIp
(Intercept)1.70[1.69; 1.71]< 0.011.70[1.69; 1.71]< 0.01
X0.58[0.56; 0.60]< 0.01–––
X_Warped–––0.92[0.91; 0.93]< 0.01
Random effects
Residual (within)0.38[0.37;0.39]< 010.10[0.09;0.10]< 0.01
Intercept (between)0.001[0.001;0.002]< 0.010.01[0.001;0.002]< 0.01
X0.56[0.54;0.57]< 0.01–––
X_warped–––0.54[0.53;0.56]< 0.01
Obs1010010100
R20.3290.829
DIC41556.127587.9

Concurrent effects are estimated within the DSEM model, while using warped data.

Dataset with missings

Next, we evaluated these results in a dataset including missing observations. ESM data are often subject to substantial missingness as participants may miss notifications, resulting in relatively high rates of missingness. There are several approaches to handling missing data, but generally speaking these missing time points introduce uncertainty in the parameter estimates. By evaluating the results in datasets with missing observations, we can assess the robustness of our findings.

Here, we focused on comparing the DSEM model with three time lags (Table 6) to the DTW model allowing both forward and backward warps (Table 7). Using the same approach—progressively adding up to three time lags in DSEM—we again found that the model with three lags provided the best fit (lowest DIC) and the highest explained variance (R2 = 0.64). The pattern of findings was consistent across the DSEM and DTW analyses and was comparable to that observed in the dataset without missing values. As in the complete dataset, the DSEM lag coefficients again differ in sign, whereas the DTW coefficients remain uniformly positive across warps. Similarly, the DTW model with three bidirectional warps yielded the highest R2 of 0.82, replicating the general pattern observed in the complete dataset. Finally, similarly as to the results with non-missing data, using DSEM on warped data yields one of the highest explained variance, as can be seen in Table 8 (R2 = 0.81).

Table 6. DSEM analysis predicting Y and from X, concurrent and delayed effects—data without missings.

VariablesModel 0Model: lag 1Model: lag 2Model: lag 3
Est95% CIpEst95% CIpEst95% CIpEst95% CIp
Fixed effects
Y (int)1.71[1.70;1.72]< 0.011.70[1.69;1.72]< 0.011.70[1.69;1.71]< 0.011.70[1.69; 1.72]< 0.01
X0.58[0.56;0.60]< 0.010.41[0.24;0.58]< 0.010.60[0.44;0.81]< 0.010.96[0.83; 1.12]< 0.01
X_lag1–––0.17[−0.00;0.35]0.03−0.27[−0.60; −0.05]< 0.01−0.70[−0.90; −0.51]< 0.01
X_lag2––––––0.26[0.14;0.43]< 0.010.00[−0.14; 0.14]0.48
X_lag3–––––––––0.35[0.27; 0.45]< 0.01
Random effects
Residual within (σ2)0.38[0.37;0.39]< 0.010.36[0.35;0.37]< 0.010.36[0.35;0.37]< 0.010.355[0.346; 0.365]< 0.01
Intercept between (τ00)0.001[0.001;0.002]< 0.010.001[0.001;002]< 0.010.001[0.001;002]< 0.010.001[0.001; 0.002]< 0.01
X concurrent–––0.68[0.49;95]< 0.010.38[0.19;0.60]< 0.010.209[0.111; 0.348]< 0.01
X_lag1–––0.71[0.51;1.00]< 0.010.22[0.04;0.43]< 0.010.151[0.032; 0.347]< 0.01
X_lag2––––––0.09[0.03;0.19]< 0.010.058[0.014; 0.146]< 0.01
X_lag3–––––––––0.043[0.017; 0.089]< 0.01
Model information
Obs10100––10100–––10100–10100––
R20.33––0.49–––0.61–0.64––
DIC18868.001––18457.783–––18444.849–18348.1––

Table 7. DTW analysis predicting Y from X, with forward window specifications 0, 1, 2, and 3—data with missings.

VariableWindow = 0Window = 3 (only forward)Window = 3 (Forward and Backward)
EstCIpEstCIpEstCIp
(Intercept)0.74[0.71; 0.77]< 0.010.40[0.37; 0.42]< 0.010.14[0.12; 0.15]< 0.01
X0.57[0.56; 0.59]< 0.01––––––
X Warped–––0.78[0.77; 0.80]< 0.010.93[0.92; 0.94]< 0.01
Obs910084358549
R2/R2 adj.0.327/0.3270.564/0.5640.818/0.818
AIC16977.00912589.5725146.444

Table 8. DSEM analysis using unwarped and warped data—with missings.

VariableWindow = 0Window = 3 (Forward and Backward)
EstCIpEstCIp
(Intercept)1.70[1.69; 1.72]< 0.011.71[1.69; 1.72]< 0.01
X0.58[0.56; 0.60]< 0.01–––
X warped–––0.93[0.92; 0.94]< 0.01
Random effects
Residual (within)0.38[0.37;0.39]< 010.09[0.09;0.10]< 0.01
Intercept (between)001[001;0.002]< 0.010.01[0.001;0.002]< 0.01
X0.55[0.54;0.57]< 0.01–––
X_warped–––0.53[0.52;0.55]< 0.01
Obs91009444
R20.3290.811
DIC37437.625108.1

Concurrent effects are estimated within the DSEM model, while using warped data.

Study 2

In the second study, we used two real-life ESM datasets to compare the performance of traditional lagged models with the DTW approach. In what follows, we specify the model tested, describe how we prepared the variables for matching, and we set up the theoretically informed model constraints (e.g., step function, window, and other warping parameters). Additionally, we present exploratory analyses on potential bidirectional relationships and individual differences in lagged effects.

Methods

Participants and procedure

To test our hypotheses, we used the data of Kuijpers et al. (2024). Both samples were collected in Belgium, with sample 1 consisting of N = 157 employees with 1,699 repeated observations (mean age = 34; 44.6% female) and sample 2 consisting of N = 96 employees with 2,151 repeated observations (mean age = 25; 53.6% female). In the first sample, conscientiousness and depletion were measured three times a day at random moments throughout the workday, across five consecutive workdays. In the second sample, data were collected over a period of 10 workdays, with participants receiving questionnaires three times a day at fixed moments (i.e., 9:30 am, 1:30 pm, and 5:30 pm). For more details on participant recruitment and characteristics, we refer to Kuijpers et al. (2024). Ethical approval for the study was granted by the ethical committee (ECHW) of the Vrije Universiteit Brussel.

Measures

In both samples, state conscientiousness was measured with the Mini-marker scale (Saucier, 1994). Depletion was assessed with the Emotional Exhaustion subscale of the Maslach Burnout Inventory (MBI-NL; Schaufeli and Van Dierendonck, 1994) in Sample 1, and with the four-item Resource Depletion scale (Oertig et al., 2013) in Sample 2. Additional information about scale reliability and descriptives can be found in Supplementary Tables S1–S3.

Analysis plan

The model tested: Because the data has a hierarchical data structure with observations nested within individuals, we performed multilevel analyses using the lme4 package in R (Bates et al., 2015)8. Importantly, considering the theoretical framework used in Kuijpers et al. (2024) in which deviations from one's typical behavior are hypothesized to be related to cognitive costs, person-centered values of conscientiousness are used in our model9. To arrive at this person-centered score, we first calculated per participant the mean state conscientiousness score across all measurement occasions, and subsequently, the person's average conscientiousness score was subtracted from their state conscientiousness scores. These person-centered scores then represent the extent to which people momentarily deviated from their typical level of conscientiousness. Additionally, because the effect of state conscientiousness on depletion might be different for people with different trait levels of conscientiousness (e.g., Pickett et al., 2019), cross-level interactions between the trait and state level are included in the model. Consequently, we test the following model (Equation 2)10

EEti=β0i+β1i EEt-1i+β2i Cti+β3i Cti2+β4i Ct-1i+β5i Ct-1i2+eij(2)

Note that this model includes both a concurrent and a lagged conscientiousness term. We retain the concurrent term as the analytic reference point representing the conventional approach in ESM research, in which same-occasion observations are treated as temporally aligned. This allows the added value of the lagged and DTW-based models to be evaluated against this baseline and prevents same-occasion covariation from being absorbed into—and thereby inflating—the lagged estimate11.

Preparing variables for matching: To briefly recap, the DTW algorithm identifies the optimal alignment between two time series by minimizing the distance between their respective signals. For this alignment to function properly, it is essential that both signals are placed on the same scale. Therefore, we used within-person z-score standardization for both the independent and dependent variables (i.e., conscientiousness and depletion), ensuring that the predictor and outcome are expressed in comparable units and have a shared interpretation. By standardizing the variables, we focus on within-person deviations from individuals' average levels—so that the distances between observations reflect meaningful covariation, rather than being confounded by differences in individuals' overall mean scores on the respective scales.

Furthermore, for DTW it is important to ensure that the relationship between the two variables operates in the same direction. Specifically, when the variables are strongly negatively correlated—such that positive deviations in one variable correspond to negative deviations in the other variable, or vice versa—it is necessary to invert one of the variables (i.e., multiply by −1) prior to applying the warping procedure. Failing to do so would lead the algorithm to minimize distances that are primarily driven by the inverse association, thereby obscuring the meaningful temporal alignment between the signals.

Constraining DTW to theoretical and temporal assumptions

With this setup in mind, we use the dtw package in R (Giorgino, 2009). This package offers a wide range of functions for specifying constraints and restriction windows, as well as options for visualizing alignments and constraints. While the package provides users with basic tools to run the algorithm, it does not support daily constraints. Because lagged effects are expected to be more profound on the same day (Kuijpers et al., 2024), and considering missingness in the data, we allowed warping within the same day only. In an exploratory step, we also allowed matching with the previous day, as there might be spill-over effects between adjacent day pairs (see also the theory on cumulative effects in Kuijpers et al., 2024). To implement these constraints, we developed a custom algorithm that loops over the observations of each individual and applies the dtw function on those observations that fall within our specified constraints (i.e., within a single day, or across consecutive day pairs).

Given that we aim to retain the reference time scale of the raw data, we implemented an asymmetric step function. This approach will only transform one of the variables, which means that we must decide whether to transform the observations of the outcome (e.g., depletion) or the predictor (e.g., conscientiousness). We argue that in our case it is most appropriate to transform the outcome variable for several reasons. First, our model includes both linear and quadratic terms, which requires the variables to share a common scale for meaningful interpretation. Second, because we include a cross-level interaction, transforming the predictor would necessitate transforming all predictors involved to ensure interpretability relative to the baseline model—adding unnecessary complexity. By selecting depletion as the transformed variable (i.e., template), it is important to note that the interpretation of the direction of algorithm shifts: the window will operate from the perspective of the template variable. For example, if we expected that conscientiousness leads to later depletion, we must constrain the algorithm to consider only past observations of conscientiousness relative to depletion, as depletion is the focal variable in the alignment (i.e., template).

Results

Sample 1: Comparing traditional lagged approaches to the DTW approach

Model comparison: When comparing a non-lagged model to a traditional lagged model in which observations are shifted by one time point (within the same day), this does not cause any changes in the statistical significance of the predictors in the model. Rather, there is an overall drop in the variance that is explained by the model ( MarginalR2 = −0.039, ConditionalR2 = −0.057), even though the model fit improved according to the AIC ( AIC = −840.182). When applying the DTW algorithm in which conscientiousness is allowed to match depletion one measurement moment later (within the same day), this again does not lead to any changes in terms of statistical significance, however, we do see a slight increase in the overall explained variance by the model ( MarginalR2 = 0.004, ConditionalR2 = 0.012), and a slight increase in model fit ( AIC = −191.313, see Table 9 for full model comparison). Furthermore, increasing the window size does not have any additional benefits with respect to the model fit, although this is not surprising given that our datasets is limited to only three daily observations. Loosening the “within-day” restriction by allowing warping between consecutive days (see Table 10) shows an increased model fit ( MarginalR2 = 0.020, ConditionalR2 = 0.030) and a strong decrease in the AIC ( AIC = −416.004). Aside from increased model fit, the relation between conscientiousness and depletion becomes statistically significant (b2 = −0.75, 95% CI [−1.45; −0.05], p = 0.035) when allowing warping between consecutive days. Interestingly, the improved fit diminishes beyond a lag of one (i.e., moving beyond matching the first measurement of a day to the final measurement of the previous day), suggesting that the DTW algorithm is not driven to align observations with increasingly distant timepoints—as is often the case with traditional lagging approaches—but rather appears to identify an optimal alignment within a window of just one prior measurement.

Table 9. Study 1 comparing baseline to simple lag 1 and DTW lag 1.

PredictorsDepletion BaseDepletion simple lag 1 within daysDepletion DTW lag 1 within daysDepletion DTW lag 2 within days
EstCIpEstCIpEstCIpEstCIp
(Intercept)5.974.68 to 7.26< 0.0015.914.62 to 7.19< 0.0015.914.62 to 7.19< 0.0015.914.62 to 7.19< 0.001
Trait C−0.64−0.88 to −0.40< 0.001−0.63−0.87 to −0.39< 0.001−0.63−0.87 to −0.39< 0.001−0.63−0.87 to −0.39< 0.001
State C−0.70−1.47 to 0.070.077−0.68−1.41 to 0.050.069−0.68−1.41 to 0.050.069−0.68−1.41 to 0.050.069
State C20.40−0.10 to 0.890.1200.29−0.18 to 0.760.2260.29−0.18 to 0.760.2260.29−0.18 to 0.760.226
Trait C × State C0.05−0.10 to 0.190.5320.04−0.10 to 0.180.5920.04−0.10 to 0.180.5920.04−0.10 to 0.180.592
Trait C × State C2−0.08−0.17 to 0.020.120−0.06−0.15 to 0.030.213−0.06−0.15 to 0.030.213−0.06−0.15 to 0.030.213
Random effects
Residual var (σ2)0.360.480.320.32
Intercept var (τ00)0.99ID1.05ID1.00ID1.00ID
Slope var (τ11)0.14ID_State_C0.06ID.State_C0.13ID.State_C0.13ID.State_C
Intercept slope cor (ρ01)−0.22ID0.26ID−0.21ID−0.21ID
ICC0.740.690.770.77
N141ID141ID141ID141ID
Obs1536102015361536
Marginal/Conditional R20.182/0.7910.143/0.7340.186/0.8130.186/0.813
AIC3422.0732581.8913230.7603230.760

Trait C, trait conscientiousness; State C, person-centered conscientiousness; State C2, quadratic term of person-centered state C; Est, estimate; Obs, observation; ICC, intra-class correlation.

Table 10. Study 1 comparing baseline to DTW lag 1, 2, and 3 between consecutive days.

PredictorsDepletion DTW lag 1 between daysDepletion DTW lag 2 between daysDepletion DTW lag 3 between days
EstCIpEstCIpEstCIp
(Intercept)6.054.75 to 7.35< 0.0016.064.76 to 7.36< 0.0016.064.76 to 7.36< 0.001
Trait C−0.66−0.90 to −0.42< 0.001−0.66−0.90 to −0.42< 0.001−0.66−0.90 to −0.42< 0.001
State C−0.71−1.42 to −0.000.049−0.75−1.45 to −0.050.035−0.75−1.45 to −0.050.035
State C20.04−0.39 to 0.470.8590.08−0.35 to 0.510.7190.08−0.35 to 0.510.720
Trait C × state C0.04−0.10 to 0.170.6060.04−0.09 to 0.170.5480.04−0.09 to 0.170.545
Trait C × state C2−0.01−0.10 to 0.070.763−0.02−0.10 to 0.060.617−0.02−0.10 to 0.060.618
Random effects
σ20.270.270.27
τ001.02ID1.03ID1.03ID
τ110.14ID.State_C0.13ID.State_C0.13ID.State_C
ρ01−0.27ID−0.26ID−0.26ID
ICC0.800.800.80
N141ID141ID141ID
Obs153615361536
Marginal/conditional R20.199/0.8410.202/0.8430.202/0.843
AIC3024.5023006.0693006.097

Trait C, trait conscientiousness; State C, person-centered conscientiousness; State C2, quadratic term of person-centered state C; Est, estimate; Obs, observation; ICC, intra-class correlation.

Substantive findings: Importantly, despite these differences in model performance, the substantive conclusions remained largely unchanged. Across all models in Table 9, only the concurrent effect of trait conscientiousness on exhaustion was statistically significant, and the cross-level interactions between trait and state conscientiousness were not, indicating that trait-level conscientiousness does not significantly moderate the strength of the within-person association between state conscientiousness and exhaustion, regardless of the lagging approach used.

Furthermore, the random effects of the DTW models closely mirror the (unlagged) baseline model, whereas the simple-lag model diverges from both: the random slope variance for state conscientiousness is roughly half as large in the simple-lag model compared to the baseline and DTW models. However, because the first observation per person in the simple-lag model cannot be lagged, almost one third of observations are lost, meaning that direct comparisons of the random effects should be interpreted with caution.

Sample 2: Comparing traditional lagged approaches to the DTW approach

Model comparison: Identical analyses and model restrictions were applied in Study 2. The simple lag model showed an overall drop in the explained variance in comparison to the baseline model ( MarginalR2 = −0.131, ConditionalR2 = −0.153) although the model fit increased ( AIC = 1106). When turning to the DTW model, the overall explained variance slightly increased ( MarginalR2 = 0.017, ConditionalR2 = 0.021) and the AIC decreased ( AIC = 105). Again, increasing the window size from—from one to two lags—does not provide additional improvements in model fit (see Table 11). Moreover, loosening the ‘within-day' restriction to allow warping between consecutive days leads to a further increase in model fit ( = AIC = 206, MarginalR2 = 0.037, ConditionalR2 = 0.051). As before, we observed diminishing returns in model fit beyond a lag window of one measurement moment (see Table 12).

Table 11. Study 2 comparing baseline to simple lag 1 and DTW lag 1.

PredictorsDepletion baseDepletion simple lag 1 within daysDepletion DTW lag 1 within daysDepletion DTW lag 2 within days
EstCIpEstCIpEstCIpEstCIp
(Intercept)7.096.37 to 7.80< 0.0017.506.74 to 8.26< 0.0017.116.39 to 7.83< 0.0017.116.39 to 7.830.001
Trait C−0.56−0.67 to −0.46< 0.001−0.62−0.73 to −0.51< 0.001−0.57−0.67 to −0.46< 0.001−0.57−0.67 to −0.46< 0.001
State C−0.61−1.07 to −0.160.0090.55−0.06 to 1.170.075−0.63−1.09 to −0.180.007−0.63−1.09 to −0.180.007
State C20.290.07 to 0.500.008−0.51−1.07 to 0.040.0710.290.08 to 0.500.0060.290.08 to 0.500.006
Trait C × State C0.00−0.06 to 0.070.889−0.06−0.15 to 0.040.2550.00−0.07 to 0.070.9230.00−0.07 to 0.070.923
Trait C × State C2−0.05−0.08 to −0.010.0070.090.00 to 0.190.045−0.05−0.08 to −0.020.004−0.05−0.08 to −0.020.004
Random effects
σ20.360.500.340.34
τ000.21ID0.20ID0.21ID0.21ID
τ110.04ID.State_C0.00ID.State_C0.04ID.State_C0.04ID.State_C
ρ01−0.33ID0.57ID−0.34ID−0.34ID
ICC0.390.290.410.41
N93ID93ID93ID93ID
Obs1947119219471947
Marginal/Conditional R20.444/0.6620.313/0.5090.461/0.6830.461/0.683
AIC3866276037613761

Trait C, trait conscientiousness; State C, person-centered conscientiousness; State C2, quadratic term of person-centered state C; Est, estimate; Obs, observation; ICC, intra-class correlation.

Table 12. Study 2 comparing baseline to DTW lag 1, 2, and 3 between consecutive days.

PredictorsDepletion DTW lag 1 between daysDepletion DTW lag 2 between daysDepletion DTW lag 3 between days
EstCIpEstCIpEstCIp
(Intercept)7.066.34 to 7.79< 0.0017.066.34 to 7.78< 0.0017.066.34 to 7.78< 0.001
Trait C−0.56−0.67 to −0.45< 0.001−0.56−0.67 to −0.45< 0.001−0.56−0.67 to −0.45< 0.001
State C−0.70−1.14 to −0.260.002−0.70−1.14 to −0.260.002−0.70−1.14 to −0.260.002
State C20.360.16 to 0.56< 0.0010.350.15 to 0.540.0010.350.15 to 0.540.001
Trait C × State C0.01−0.06 to 0.080.7780.01−0.06 to 0.080.7600.01−0.06 to 0.080.760
Trait C × State C2−0.06−0.09 to −0.03< 0.001−0.06−0.09 to −0.03< 0.001−0.06−0.09 to −0.03< 0.001
Random effects
σ20.300.300.30
τ000.22ID0.22ID0.22ID
τ110.04ID.State_C0.04ID.State_C0.04ID.State_C
ρ01−0.36ID−0.37ID−0.37ID
ICC0.450.450.45
N93ID93ID93ID
Obs194719471947
Marginal/Conditional R20.481/0.7130.482/0.7130.482/0.713
AIC355535433543

Trait C, trait conscientiousness; State C, person-centered conscientiousness; State C2, quadratic term of person-centered state C; Est, estimate; Obs, observation; ICC, intra-class correlation.

Substantive findings: Although the increased explained variance is relatively small, the conclusion drawn from the different models differ substantially. That is, the traditional lag model showed that the linear and curvilinear effect of state conscientiousness on depletion were not statistically significant (b2 = 0.55, 95% CI [−0.06; 1.17], p = 0.075; b3 = −0.51, 95% CI [−1.07; 0.04], p = 0.071). When applying the DTW algorithm in which conscientiousness is allowed to match depletion one measurement moment later that day, the linear and quadratic effect of conscientiousness become statistically significant, and the size of the confidence interval of the fixed effect estimates decreases (b2= −0.57, 95% CI [−0.67; −0.46], p = 0.007; b3 = −0.63, 95% CI [−1.09; −0.18], p = 0.006). Thus, following the traditional approach we would have concluded that there is no lagged effect of state conscientiousness, while such effect does show when using DTW.

Notably, the simple-lag model did not merely show fewer statistical significant effects, the sign of the estimate of the interaction reversed. That is, the interaction between trait and the curvilinear state conscientiousness was statistically significant throughout, but its sign reversed in the simple-lag model. This indicated that the effect of state conscientiousness on depletion is stronger for people with higher baseline conscientiousness levels when using the fixed lag approach, while it is weaker when using the DTW. This further illustrates that the fixed one-occasion shift did not merely find fewer significant associations but also altered their apparent direction, whereas the DTW-based alignment reproduced the same pattern as the unlagged baseline model. When turning to the random effects, the random slope variance for state conscientiousness was essentially zero in the simple-lag model, whereas those of the DTW model were again identical to the baseline model.

Exploratory analysis: accommodating a bi-directional relationship

Because the relationship between state conscientiousness and depletion might be reciprocal (i.e., people might fail to act in a conscientious manner when they are depleted), we performed additional analyses that allows for such bidirectionality. Although Kuijpers et al. (2024) performed a follow-up analysis showing that depletion was related to later lower levels of conscientiousness, the authors were reluctant to overinterpret this finding as the model was heavily parametrized, which resulted in convergence issues. We will further explore this issue by using DTW to compare the model fit of three models with varying window types, allowing depletion to align with (1) previous, (2) future, (3) both previous and future observations of state conscientiousness within the same day (i.e., a window size of one). In sample 1, results showed that depletion has a lagged effect on state conscientiousness. This model slightly outperformed the model assuming that conscientious behavior has a lagged effect on depletion in terms of the explained variance ( MarginalR2 = 0.004/ ConditionalR2 = 0.002), although it had a higher AIC value ( AIC = 15.984). The model allowing for warping in both directions, has a slightly larger increase in explained variance ( MarginalR2 = 0.009/ ConditionalR2 = 0.010) and a substantial decrease in AIC ( AIC = −68.643). This indicates that the model allowing for bidirectional lagged effects provided a better fit to the data than the models assuming a single directional effect (see Table 13).

Table 13. Comparison of different effect directions study 2.

PredictorsModel 1 depletion DTW Lag 1 within days state C –> depletionModel 2 depletion DTW Lag 1 within days state C<- depletionModel 3 depletion DTW Lag 1 within days state C<-> depletion
EstCIpEstCIpEstCIp
(Intercept)5.914.62 to 7.19< 0.0015.974.67 to 7.27< 0.0015.924.63 to 7.21< 0.001
Trait C−0.63−0.87 to −0.39< 0.001−0.64−0.88 to −0.40< 0.001−0.63−0.87 to −0.39< 0.001
State C−0.68−1.41 to 0.050.069−0.74−1.47 to −0.000.049−0.76−1.48 to −0.040.038
State C20.29−0.18 to 0.760.2260.36−0.11 to 0.830.1320.31−0.14 to 0.770.179
Trait C × State C0.04−0.10 to 0.180.5920.05−0.09 to 0.190.5080.05−0.09 to 0.180.491
Trait C × State C2−0.06−0.15 to 0.030.213−0.07−0.16 to 0.020.121−0.06−0.15 to 0.030.163
Random effects
σ20.320.320.30
τ001.00ID1.02ID1.00ID
τ110.13ID.State_C0.13ID.State_C0.13ID.State_C
ρ01−0.21ID−0.19ID−0.18ID
ICC0.770.770.78
N141ID141ID141ID
Obs153615361536
Marginal/Conditional R20.186/0.8130.190/0.8150.195/0.823
AIC3230.7603246.4743162.117

Trait C, trait conscientiousness; State C, person-centered conscientiousness; State C2, quadratic term of person-centered state C; Est, estimate; Obs, observation; ICC, intra-class correlation.

In sample 2, a similar pattern of findings was observed. The model allowing depletion to have a lagged effect on conscientious behavior slightly outperformed the model assuming that conscientious behavior has a lagged effect on depletion in terms of the explained variance ( MarginalR2 = 0.007/ ConditionalR2 = 0.002), and showed a lower AIC value (AIC= −57.274). Yet, the model that allows for lagged effects in both directions appears to improve model fit most, with a larger increase in explained variance ( MarginalR2 = 0.014/ ConditionalR2 = 0.010) and a greater decrease in AIC (AIC = −87.209). This again indicates that the model accommodating lagged effects in both directions provides a stronger fit to the data than the models assuming a single direction (see Table 14).

Table 14. Comparison of different effect directions study 2.

PredictorsDepletion DTW lag 1 within days state C -> depletionDepletion DTW lag 1 within days state C<- depletionDepletion DTW lag 1 within days state C<-> depletion
EstCIpEstCIpEstCIp
(Intercept)7.106.38 to 7.82< 0.0017.156.45 to 7.85< 0.0017.156.44 to 7.85< 0.001
Trait C−0.57−0.67 to −0.46< 0.001−0.57−0.68 to −0.47< 0.001−0.57−0.68 to −0.47< 0.001
State C−0.64−1.08 to −0.200.005−0.62−1.06 to −0.180.006−0.62−1.06 to −0.180.006
State C20.300.09 to 0.510.0050.230.03 to 0.440.0270.240.04 to 0.450.019
Trait C × State C0.00−0.06 to 0.070.8890.00−0.06 to 0.070.9310.00−0.07 to 0.070.986
Trait C × State C2−0.05−0.08 to −0.020.004−0.04−0.07 to −0.010.018−0.04−0.07 to −0.010.013
Random effects
σ20.340.330.32
τ000.21ID0.20ID0.20ID
τ110.04ID.State_C0.04ID.State_C0.04ID.State_C
ρ01−0.34ID−0.32ID−0.32ID
ICC0.410.410.41
N93ID93ID93ID
Obs194719471947
Marginal/conditional R20.460/0.6810.467/0.6830.474/0.691
AIC3764.5383707.2643677.329

Trait C, trait conscientiousness; State C, person-centered conscientiousness; State C2, quadratic term of person-centered state C; Est, estimate; Obs, observation; ICC, intra-class correlation.

Discussion

The aim of the current study was to introduce DTW as a flexible analytical approach for examining varying lagged effects in behavioral and psychological timeseries data. The strength of the DTW approach lies in its ability to accommodate intra- and inter-individual variation in the onset and duration of individual responses—something that traditional fixed-time lag analyses cannot (or only partly) account for. This is crucial because the underlying relationship between two occurrences is often not linear, and applying a fixed time lag can in such circumstances lead to inaccurate interferences. Specifically, fixed lagging risks misalignment for instances where effects are actually concurrent, as responses might differ across situations, time, and individuals. In addition to these misalignment concerns, another limitation of the traditional approach is the loss of data. Since each participant contributes to their own timeseries, fixed lagging inevitably discards at least as many observations as there are participants. This loss is even greater when lags are restricted within days or when the data contains many missing observations, as a greater number of observations are discarded to meet these restrictions. This, in turn, can substantially reduce the power of the model. Consequently, the traditional lag model will not offer the same ability to detect meaningful relationships as models that capitalize on DTW.

Our results showed that by simultaneously accounting for both concurrent and lagged effects using the DTW algorithm, the model fit and explained variance significantly increased, thereby supporting Hypothesis 1. The strength of the DTW approach lies in its flexibility; it is not constrained by a fixed time lag but instead identifies the observations within a given time window that minimizes the overall distance between two timeseries. For example, setting a time window of three (i.e., allowing matches up to three timepoints away) does not automatically suggest that the algorithm will warp those timepoints, rather, it warps those timepoints if this minimizes the overall distance or mismatch. As shown in Study 2, the increase in model fit diminishes substantially once the time window exceeded one for models spanning consecutive days. This suggests that the alignment was close to optimal using a time lag of one, whit only a few observations benefiting from additional flexibility. Study 1 further demonstrated that, in case the true underlying dependency structure is inherently bidirectional, DTW is able to recover the dependency structure embedded in the data. In doing so, DTW not only produced a model that was superior to that obtained when restricting the analysis to only forward lags, but also a model that aligned more closely with theoretical expectations about bidirectional lagged effects. Beyond improving model fit, the DTW-based coefficients obtained in Study 2 also proved more parsimonious and easier to interpret than their DSEM counterparts: whereas the DSEM lag coefficients changed sign across lags, the DTW coefficients remained uniformly signed and increased steadily in magnitude across window sizes.

Aside from finding the optimal time-lag in a given time window, exploratory analyses additionally showed that the algorithm can account for time lags in both directions simultaneously. This is especially useful when there are no clear theoretical expectations about the direction of the associations between two variables. Cole and Maxwell (2003) argue that in the social sciences, the timing of assessment is often driven more by convenience and tradition than by theory or empirical evidence. Similarly, Dwyer (1983) demonstrated that using time lags that are too long can lead to underestimation of causal effects. Although there is little systematic research investigating the most appropriate time lags for panel studies, a few studies have used simulated data to explore optimal time lags (Dormann and Griffin, 2015). A key contribution of the DTW approach is that it can serve as an exploratory tool for theory development. This responds to the recent call of Hopwood et al. (2022a) for more exploratory research aimed at refining our models with greater temporal specificity.

Theoretical applications of DTW in behavioral science

DTW also holds considerable promise for advancing theory development. Specifically, DTW offers a flexible framework that can be applied across diverse behavioral domains to test temporal and dynamic theoretical propositions. For example, DTW can be used to test the basic premises of the Job Demands-Resource Theory (JD-R, Bakker et al., 2023). Recent work by (?) places chronological time at the center of the theory through gain cycles—in which work engagement, proactive behavior, and resources reinforce one another—and loss cycles, in which job strain, dysfunctional behavior, and demands do the same. When sustained, these cycles develop into upward gain spirals or downward loss spirals (Hobfoll et al., 2018; Salanova et al., 2010). Because the relationships within these spirals are inherently bidirectional—strain may drive self-undermining, but self-undermining also drives strain—DTW is particularly well suited to examine them, offering a more detailed view of how such recursive cycles unfold over time.

Similarly, the premises of Conservation of Resources theory (COR; Hobfoll, 1989) increasingly emphasize how resource dynamics unfold over time (Shipp and Cole, 2015). According to Hobfoll et al. (2018), these dynamics take many forms, “ranging from the amount of time over which resources are lost or gained (e.g., acute versus chronic stressors), to the length of recovery periods necessary to regain resources, to the specific timing that a resource becomes available relative to the timing of resource loss” (p. 116). DTW can address such questions by examining how gains, losses, and replenishment of resources and demands affect outcomes in terms of both onset and duration. Moreover, because breaking out of loss spirals is central to resilience, the role of individual differences is critical (Hobfoll et al., 2018; Van den Heuvel et al., 2013). DTW is particularly suited here, as it explicitly allows for individual warping paths or alignment trajectories and can therefore reveal how resource gain and loss function at the person level.

Lastly, DTW can help test theories that have received mixed support under traditional methods because those methods fail to account for temporal differentiation. A telling example is the strength model of self-control (Baumeister et al., 1994), which holds that willful action depletes inner resources and causes subsequent self-control failure. Both the conceptual basis and the empirical robustness of ego-depletion have been challenged (Inzlicht and Schmeichel, 2012), while at the same time, work on mental fatigue suggests that self-regulatory failure is real but slow to materialize—possibly requiring hours of effort rather than minutes (Blain et al., 2016; Hagger et al., 2016). This shifts the attention from short-term laboratory tasks to day-to-day exertion of self-control (Altena et al., 2008; Meldrum et al., 2020; Walker et al., 2008).

Limitations and directions for future research

While DTW is a powerful and flexible tool that will help accommodate varying lagged effects, it is not without limitations. First, while DTW is model agnostic—meaning it can easily be applied to a variety of modeling approaches such as structural equation models, decision tree models, and linear regression models—incorporating lagged effects through DTW can complicate the interpretability of the model. In particular, when extensive warping or temporal alignment occurs, the fixed effects can no longer be interpreted solely as representing concurrent relationships between the dependent and independent variable. Instead, they reflect a mixture of both lagged and concurrent relationships, and those may vary between individuals. Given that the main assumption of our statistical model is that we are capturing concurrent effects, it becomes questionable whether the fixed effects of the un-warped model are meaningful when the data exhibit strong warping paths or alignment trajectories. From this perspective, it may be valuable to filter out lagged observations and estimate the model solely on the un-warped (i.e., concurrent) observations. Doing so would yield a less biased estimate of the true concurrent effects12.

Furthermore, although the data used in this study is interesting due to the implied theoretical assumed (bi)directionality, a limitation is that it only contains three measurement moments per day. The utility of the DTW algorithm greatly increases when having more observations per day, as this will not only increase the possibility of capturing delayed effects within the day, but will also increase the temporal granularity of the relationship. Having a higher temporal granularity means that the warps made by the model are less abrupt, indicating that we can more accurately assess lagged effects. Lastly, as with any statistical approach, the DTW approach is not entirely assumption-free. Specifically, the main underlying assumption of the algorithm is that the two variables are constantly exerting a push and pull on each other (Giorgino, 2009). In other words, observed distances or mismatch between observations are always assumed to be caused by the presence of a lagged effect between the two variables. This, of course, represents an over-simplification of reality, as it is likely that other unobserved variables also shape the enactment of either variable at any given time.

A related consideration concerns the possibility that the flexibility of DTW may artificially improve model fit by allowing excessive temporal adjustments. Because DTW identifies the alignment that minimizes the distance between two time series, unconstrained warping can produce alignments that reduce mismatch without reflecting meaningful temporal correspondence. This issue, often referred to as pathological warping, occurs when the algorithm exploits excessive flexibility in the warping path, for example by repeatedly matching a single observation to multiple observations in the other time series (Zhang et al., 2017).

Importantly, this limitation does not imply that DTW should not be used, as similar concerns apply to many flexible modeling approaches. Rather, it highlights the importance of explicitly constraining and evaluating the flexibility introduced by the algorithm. In DTW, constraints such as the window size and step function serve not only to incorporate theoretical assumptions about plausible temporal dynamics but also to prevent excessive warping. Researchers should therefore avoid selecting DTW configurations solely based on the lowest final DTW distance (i.e., the lowest overall mismatch after alignment) and instead evaluate whether increases in temporal flexibility yield meaningful improvements in model fit. For example, examining whether improvements diminish as window sizes increase can provide an indication of whether additional flexibility contributes substantive information or merely reflects greater freedom in the alignment procedure.

Furthermore, future applications of DTW may benefit from permutation-based evaluations that compare the observed alignment against alignments obtained after disrupting the temporal correspondence between time series. Specifically, researchers can create a reference distribution by repeatedly applying DTW after disrupting the temporal pairing between the two time series using permutation procedures that preserve relevant properties of the data, such as within-person temporal dependencies, where possible. The resulting distribution provides an estimate of how much alignment improvement could be obtained purely from the flexibility of the DTW algorithm. If the alignment observed in the original data is not substantially better than these randomized alignments, this would suggest that the apparent improvement may largely reflect the flexibility of the warping procedure rather than a meaningful temporal relationship. Such approaches can help determine whether the observed temporal correspondence exceeds what would be expected from the alignment flexibility inherent to DTW, by comparing the observed alignment with the level of alignment obtained under disrupted temporal correspondence. Additionally, future research could examine how the choice of step function influences DTW results. In the present study, we used an asymmetric step function, which aligns one time series to another, such that the resulting distance depends on which series is treated as the reference. In contrast, Pasteuning et al. (2025) used a symmetric step pattern to examine temporal associations in daily life stress reactivity. An asymmetric step pattern may be appropriate when one time series is theoretically considered the reference, whereas a symmetric step pattern may be preferable when both series are considered equally important and comparability across participants is a priority. Although both approaches capture temporal relationships, they differ in how distances are computed and normalized, which may affect comparisons across participants with unequal numbers of observations. Future studies could directly compare these approaches within the same dataset to determine how robust findings are to this methodological choice.

Importantly, the current study uses standard DTW, which constrains the alignment to the first and last observations of each series, meaning that endpoint discrepancies contribute to the distance. Open-end DTW (also referred to as prefix- or suffix-invariant DTW) provides an alternative by allowing the alignment to start and end at different points, thereby reducing the influence of discrepancies concentrated at the beginning or end of a series. Similarly, Derivative Dynamic Time Warping (DDTW), which focuses on the shape of the trajectories rather than their absolute levels, provides another commonly used alternative (e.g., Keogh and Pazzani, 2001; Helwig et al., 2011; Yang et al., 2017). Both approaches could be considered in future applications.

Finally, an additional consideration of the DTW approach might be causality. While DTW can identify whether one time series tends to precede another within a given time window, this should not be interpreted as evidence of true causal influence. The temporal precedence detected by DTW reflects temporal alignment rather than causal mechanisms, and the allowable time window for matching must be theoretically justified. These constraints help reduce the risk of spurious alignments, although subsequent statistical analyses—such as regression on warped data—still require careful interpretation and appropriate controls. Nonetheless, DTW can inform theory-driven hypotheses about temporal dynamics and individual differences in lag structures, which can be tested in subsequent confirmatory studies. For example, DTW results might reveal stronger lagged effects or more frequently fluctuating warping patterns between subgroups, suggesting new directions for sampling schemes in future research.

Conclusion

A key limitation of the traditional fixed-lag approach is its inability to accommodate variations in lagged effects within and across individuals. To date, behavioral research has not widely applied statistical methods that account for the fact that the same behavior can elicit different responses at different measurement moments, both in terms of onset and duration. To address this issue, we introduce DTW as a technique capable of capturing such individual variability in responses. In two studies, in both simulated and real-life datasets, we showed that by simultaneously accounting for both concurrent and lagged effects with the DTW algorithm model fit is significantly improved in comparison to using conventional methods, such as DSEM and traditional lag models.

Generative AI statement

The author(s) declared that Generative AI was not used in the creation of this manuscript.

Any alternative text (alt text) provided alongside figures in this article has been generated by Frontiers with the support of artificial intelligence and reasonable efforts have been made to ensure accuracy, including review by the authors wherever possible. If you identify any issues, please contact us.

Publisher's note

All claims expressed in this article are solely those of the authors and do not necessarily represent those of their affiliated organizations, or those of the publisher, the editors and the reviewers. Any product that may be evaluated in this article, or claim that may be made by its manufacturer, is not guaranteed or endorsed by the publisher.

Supplementary material

The Supplementary Material for this article can be found online at: https://www.frontiersin.org/articles/10.3389/forgp.2026.1892016/full#supplementary-material

Supplementary material Supplementary material at the source

Footnotes

Edited by: Alexandre J. S. Morin, Concordia University, Canada

Reviewed by: Lars-Erik Malmberg, University of Oxford, United Kingdom

Kevin Grimm, Arizona State University, United States

Footnotes

also referred to as acting counterdispositonal conscientiousness or ‘acting out of character', see Kuijpers et al. (2024).

Here, cost and distance refer to the same underlying concept: the mismatch between observations. Distance is typically used to describe the raw difference between two values (e.g., Euclidean distance), whereas cost refers to how these mismatches are incorporated within the DTW algorithm, where they are organized in the cost matrix and used to identify the optimal warping path.

Dynamic Time Warping is a very flexible algorithm that also allows the matching of partial timeseries (i.e., a shorter time series to a longer one). Having timeseries of different sizes has different implications for how certain constraints in the algorithm work. This is, however, outside of the scope of our research as we are focusing on co-occurrence, and as such have equal length time series. The interested reader can refer to (Giorgino, 2009) for more information on the matching of partial time series.

The terms query and template are methodological terms and do not imply a variable's status as dependent or independent variable. Instead, query refers to the time series that is held constant during the alignment process and defines the time scale onto which the other series is warped. See the “ Constraining DTW to Theoretical and Temporal Assumptions” section of Study 2 for an explanation of why the outcome variable is often preferred as the template.

Although random effects can capture inter-individual differences in the magnitude of lagged effects, they still assume a fixed lag structure across individuals and thus cannot account for individual-specific timing differences.

DTW is therefore not used to align trajectories across individuals, but DTW-derived characteristics (e.g., the degree and timing of warping) can subsequently be compared between individuals to examine individual differences in temporal dynamics.

Because the random slopes of the DTW models were consistently close to zero and often resulted in singular fits, we did not report these estimates. Moreover, in Study 1, between-person variability was introduced in the timing of the associations rather than in their strength, therefore, random slopes (which capture differences in association strength after accounting for timing) were not the primary parameter of interest. In Study 2, we report the random slopes for both the fixed-lag regression model and the DTW model.

Although Kuijpers et al. (2024) used DSEM in Mplus to examine concurrent and lagged effects, the tested model is identical. As the DSEM approach was demonstrated in the previous sample, we now use mutli-level regression modeling to test the proposed relationships.

This idea is reflected in the Personality Dynamics model (PersDyn model, Sosnowska et al., 2019) and the Behavioral Concordance Model (BCM, Moskowitz and Coté, 1995). See Kuijpers et al. (2024) for a more thorough explanation of the theoretical framework.

EE = Emotional Exhaustion; C = Conscientiousness; t = measurement occasion; i = individual. Lagged terms are indicated by t−1, and squared terms represent the quadratic effect of conscientiousness.

Because a same-occasion association carries no inherent directionality, we interpret the concurrent term descriptively rather than as evidence of a directional effect. We nevertheless specify it as a regression path to allow direct comparison with the lagged and DTW-aligned terms within the same regression framework. The lagged term is interpreted as reflecting temporal precedence, albeit not causal direction.

This could be equally interesting when individual warping paths show substantial variation, as considerable individual differences in lagged effects may obscure results.

Statements

Conflict of interest

The author(s) declared that this work was conducted in the absence of any commercial or financial relationships that could be construed as a potential conflict of interest.

Funding

The author(s) declared that financial support was received for this work and/or its publication. This work was supported by the Vlaamse Interuniversitaire Raad (Grant iBOF/21/090) and co-funded by the HELIOS-VUB Chair on Mental Wellbeing at Work.

Data availability

The data, materials, and other supporting information underlying the findings of this study are openly available on the Open Science Framework (OSF) at: https://osf.io/a96st/?view_only=bfabcc5578c6405c9d62f24a891dc237. Further inquiries can be directed to the corresponding author.

Ethics approval

The studies involving humans were approved by Ethics Committee of the Vrije Universiteit Brussel (ECHW_129). The studies were conducted in accordance with the local legislation and institutional requirements. The participants provided their written informed consent to participate in this study. Written informed consent was obtained from the individual(s) for the publication of any potentially identifiable images or data included in this article.

Author contributions

JV: Conceptualization, Data curation, Formal analysis, Methodology, Validation, Visualization, Writing – original draft, Writing – review & editing. EK: Conceptualization, Investigation, Methodology, Project administration, Resources, Writing – original draft, Writing – review & editing. JH: Conceptualization, Methodology, Resources, Supervision, Writing – original draft, Writing – review & editing.

References

  1. Aguinis H., Pierce C. A., Bosco F. A., Muslin I. S. (2009). First decade of organizational research methods: trends in design, measurement, and data-analysis topics. Organ. Res. Methods 12, 69 – 112. doi: doi:10.1177/1094428108322641
  2. Altena E., Van Der Werf Y. D., Strijers R. L., Van Someren E. J. W. (2008). Sleep loss affects vigilance: Effects of chronic insomnia and sleep therapy. J. Sleep Res. 17, 335 – 343. doi: doi:10.1111/j.1365-2869.2008.00671.x
  3. Asparouhov T., Hamaker E. L., Muthén B. (2018). Dynamic structural equation models. Struct Equ. Model. 25, 359 – 388. doi: doi:10.1080/10705511.2017.1406803
  4. Asparouhov T., Muthén B. (2022). Practical aspects of dynamic structural equation models. Muthén and Muthén. Available online at: (Accessed September 9, 2026).
  5. Bakker A. B., Demerouti E., Sanz-Vergel A. I. (2014). Burnout and work engagement: the JD-R approach. Annu. Rev. Organ. Psychol. Organ. Behav. 1, 389 – 411. doi: doi:10.1146/annurev-orgpsych-031413-091235
  6. Bakker A. B., Demerouti E., Sanz-Vergel A. (2023). Job demands-resources theory: ten years later. Annu. Rev. Organ. Psychol. Organ. Behav. 10, 25 – 53. doi: doi:10.1146/annurev-orgpsych-120920-053933
  7. Basagaña X., Barrera-Gómez J. (2022). Reflection on modern methods: visualizing the effects of collinearity in distributed lag models. Int. J. Epidemiol. 51, 334 – 344. doi: doi:10.1093/ije/dyab179
  8. Bates D., Mächler M., Bolker B., Walker S. (2015). Fitting linear mixed-effects models using lme4. J. Stat. Softw. 67, 1 – 48. doi: doi:10.18637/jss.v067.i01
  9. Baumeister R. F., Heatherton T. F., Tice D. M. (1994). Losing Control: How and Why People Fail at Self-regulation. Cambridge, MA: Academic Press.
  10. Black A. C., Harel O., Matthews G. (2012). “Techniques for analyzing intensive longitudinal data with missing values,” in Handbook of Research Methods for Studying Daily Life, eds. M. R. Mehl, and T. S. Conner (New York, NY: The Guilford Press), 339 – 356.
  11. Blain B., Hollard G., Pessiglione M. (2016). Neural mechanisms underlying the impact of daylong cognitive work on economic decisions. Proc. Natl. Acad. Sci. 113, 6967 – 6972. doi: doi:10.1073/pnas.1520527113
  12. Brackett M. A., Mayer J. D. (2003). Convergent, discriminant, and incremental validity of competing measures of emotional intelligence. Pers. Soc. Psychol. Bull. 29, 1147 – 1158. doi: doi:10.1177/0146167203254596
  13. Chaffin D., Heidl R., Hollenbeck J. R., Howe M., Yu A., Voorhees C.. (2017). The promise and perils of wearable sensors in organizational research. Organ. Res. Methods 20, 3 – 31. doi: doi:10.1177/1094428115617004
  14. Cole D. A., Maxwell S. E. (2003). Testing mediational models with longitudinal data: questions and tips in the use of structural equation modeling. J. Abnorm. Psychol. 112, 558 – 577. doi: doi:10.1037/0021-843X.112.4.558
  15. Di Brina C., Niels R., Overvelde A., Levi G., Hulstijn W. (2008). Dynamic time warping: a new method in the study of poor handwriting. Hum. Mov. Sci. 27, 242 – 255. doi: doi:10.1016/j.humov.2008.02.012
  16. Dormann C., Griffin M. A. (2015). Optimal time lags in panel studies. Psychol. Methods 20, 489 – 505. doi: doi:10.1037/met0000041
  17. Driver C. C., Voelkle M. C. (2018). Hierarchical Bayesian continuous time dynamic modeling. Psychol. Methods 23, 774 – 799. doi: doi:10.1037/met0000165
  18. Driver C. C., Oud J. H. L., Voelkle M. C. (2017). Continuous time structural equation modeling with R package ctsem. J. Stat. Softw. 77, 1 – 35. doi: doi:10.18637/jss.v077.i05
  19. Dwyer J. H. (1983). Statistical Models for the Social and Behavioral Sciences. Oxford: Oxford University Press.
  20. Fang Y., Wang L. (2024). Dynamic structural equation models with missing data: data requirements on N and T. Struct. Equ. Model. 31, 891 – 908. doi: doi:10.1080/10705511.2023.2287967
  21. Giorgino T. (2009). Computing and visualizing dynamic time warping alignments in R: the dtw package. J. Stat. Softw. 31, 1 – 24. doi: doi:10.18637/jss.v031.i07
  22. Hagger M. S., Wood C., Stiff C., Chatzisarantis N. L. D. (2010). Ego depletion and the strength model of self-control: a meta-analysis. Psychol. Bull. 136, 495 – 525. doi: doi:10.1037/a0019486
  23. Hagger M. S., Chatzisarantis N. L. D., Alberts H., Anggono C. O., Batailler C., Birt A. R.. (2016). A multilab preregistered replication of the ego-depletion effect. Perspect. Psychol. Sci. 11, 546 – 573. doi: doi:10.1177/1745691616652873
  24. Helwig N. E., Hong S., Hsiao-Wecksler E. T., Polk J. D. (2011). Methods to temporally align gait cycle data. J. Biomech. 44, 561 – 566. doi: doi:10.1016/j.jbiomech.2010.09.015
  25. Hobfoll S. E. (1989). Conservation of resources: a new attempt at conceptualizing stress. Am. Psychol. 44, 513 – 524. doi: doi:10.1037/0003-066X.44.3.513
  26. Hobfoll S. E., Halbesleben J., Neveu J. P., Westman M. (2018). Conservation of resources in the organizational context: the reality of resources and their consequences. Annu. Rev. Organ. Psychol. Organ. Behav. 5, 103 – 128. doi: doi:10.1146/annurev-orgpsych-032117-104640
  27. Hollenstein T. (2015). This time, it's real: affective flexibility, time scales, feedback loops, and the regulation of emotion. Emot. Rev. 7, 308 – 315. doi: doi:10.1177/1754073915590621
  28. Hopwood C. J., Bleidorn W., Wright A. G. (2022a). Connecting theory to methods in longitudinal research. Perspect. Psychol. Sci. 17, 884 – 894.
  29. Hopwood C. J., Bleidorn W., Wright A. G. C. (2022b). The future is dynamic: a call for intensive longitudinal data in personality disorder research. Personal. Disord. Theory Res. Treat. 13, 1 – 8. doi: doi:10.1177/17456916211008407
  30. Inzlicht M., Schmeichel B. J. (2012). What is ego depletion? Toward a mechanistic revision of the resource model of self-control. Perspect. Psychol. Sci. 7, 450 – 463. doi: doi:10.1177/1745691612454134
  31. Jebb A. T., Tay L. (2017). Introduction to time series analysis for organizational research: methods for longitudinal analyses. Organ. Res. Methods 20, 61 – 94. doi: doi:10.1177/1094428116668035
  32. Jebb A. T., Tay L., Wang W., Huang Q. (2015). Time series analysis for psychological research: examining and forecasting change. Front. Psychol. 6: 727. doi: doi:10.3389/fpsyg.2015.00727
  33. Ji L., Chow S. M., Schermerhorn A. C., Jacobson N. C., Cummings J. L. (2018). Handling missing data in the modeling of intensive longitudinal data: a comparison of multiple imputation methods. Psychol. Methods 23, 454 – 473. doi: doi:10.1080/10705511.2017.1417046
  34. Keogh E. J., Pazzani M. J. (2001). “Derivative dynamic time warping,” in Proceedings of the 2001 SIAM international conference on data mining (Society for Industrial and Applied Mathematics), 1 – 11. doi: doi:10.1137/1.9781611972719.1
  35. Killingsworth M. A., Gilbert D. T. (2010). A wandering mind is an unhappy mind. Science. 330, 932 – 932. doi: doi:10.1126/science.1192439
  36. Kuijpers E., Pickett J., Wille B., Hofmans J. (2024). Does it pay off to act conscientiously, both now and later? Examining concurrent, lagged, and cumulative effects of state conscientiousness. Eur. J. Pers. 38, 21 – 35. doi: doi:10.1177/08902070221124705
  37. Kuiper R. M., Ryan O. (2020). Meta-analysis of lagged regression models: a continuous-time approach. Struct. Equ. Model. 27, 396 – 413. doi: doi:10.1080/10705511.2019.1652613
  38. Kuppens P., Allen N. B., Sheeber L. B. (2010). Emotional inertia and psychological maladjustment. Psychol. Sci. 21, 984 – 911 doi: doi:10.1177/0956797610372634
  39. Kurbalija V., von Bernstorff C., Burkhard H. D., Nachtwei J., Ivanović M., Fodor L. (2012). “Time-series mining in a psychological domain,” in Proceedings of the Fifth Balkan Conference in Informatics (New York, NY; Association for Computing Machinery (ACM)), 58 – 63. doi: doi:10.1145/2371316.2371328
  40. Little R. J., Rubin D. B. (2002). Maximum likelihood for general patterns of missing data: introduction and theory with ignorable nonresponse. Statistical Analysis with Missing Data, 2nd Edn. (Hoboken, NJ: Wiley), 164 – 189. doi: doi:10.1002/9781119013563.ch8
  41. McNeish D., Hamaker E. L. (2020). A primer on two-level dynamic structural equation models for intensive longitudinal data in Mplus. Psychol. Methods 25, 610 – 635. doi: doi:10.1037/met0000250
  42. McNeish D. (2019). Two-level dynamic structural equation models with small samples. Struct. Equ. Modeling. 26, 948 – 966. doi: doi:10.1080/10705511.2019.1578657
  43. Meldrum R. C., Barnes J. C., Hay C. (2015). Sleep deprivation, low self-control, and delinquency: A test of the strength model of self-control. J. Youth Adolesc. 44, 465 – 477. doi: doi:10.1007/s10964-013-0024-4
  44. Mitchell T. R., James L. R. (2001). Building better theory: time and the specification of when things happen. Acad. Manag. Rev. 26, 530 – 547. doi: doi:10.2307/3560240
  45. Moskowitz D. S., Coté S. (1995). Do interpersonal traits predict affect? A comparison of three models. J. Pers. Soc. Psychol. 69: 915. doi: doi:10.1037/0022-3514.69.5.915
  46. Muthén L. K., Muthén B. O. (1998-2017). Mplus User's Guide, 8th Edn. Los Angeles, CA: Muthén & Muthén.
  47. Navarro J., Roe R. A., Artiles M. I. (2015). Taking time seriously: changing practices and perspectives in work/organizational psychology. Revista de Psicología del Trabajo y de las Organizaciones 31, 135 – 145. doi: doi:10.1016/j.rpto.2015.07.002
  48. Oertig D., Schüler J., Schnelle J., Brandstätter V., Roskes M., Elliot A. J. (2013). Avoidance goal pursuit depletes self-regulatory resources. J. Pers. 81, 365 – 375. doi: doi:10.1111/jopy.12019
  49. Pasteuning J., Broeder C., Sep M., Elzinga B., Penninx B., Vinkers C.. (2025). Dynamic time warping to model daily life stress reactivity in a clinical and non-clinical sample—An ecological momentary assessment study. J. Affect. Disord. 390: 119833. doi: doi:10.1016/j.jad.2025.119833
  50. Pickett J., Hofmans J., De Fruyt F. (2019). Extraversion and performance approach goal orientation: an integrative approach to personality. J. Res. Pers. 82: 103846. doi: doi:10.1016/j.jrp.2019.103846
  51. Ramsay J. O., Silverman B. W. (2005). Functional Data Analysis, 2nd Edn. Berlin: Springer.
  52. Sakoe H., Chiba S. (1978). “A dynamic programming approach to continuous speech Recognition,” in Proceedings of the Seventh International Congress on Acoustics, Budapest (Akadémiai Kiadó), 65 – 69.
  53. Sankoff D., Kruskal J. B. (1983). Time Warps, String Edits, and Macromolecules. Reading, MA: Addison-Wesley Publishing Company.
  54. Saucier G. (1994). Mini-markers: a brief version of goldberg's unipolar big-five markers. J. Pers. Assess. 63, 506 – 516. doi: doi:10.1207/s15327752jpa6303_8
  55. Salanova M., Schaufeli W. B., Xanthopoulou D., Bakker A. B. (2010). “The gain spiral of resources and work engagement: Sustaining a positive worklife.” in Work Engagement: A Handbook of Essential Theory and Research, eds. A. B. Bakker, and M. P. Leiter (East Sussex: Psychology Press), 118 – 131.
  56. Scandura T. A., Williams E. A. (2000). Research methodology in management: current practices, trends, and implications for future research. Acad. Manag. J. 43, 1248 – 1264. doi: doi:10.2307/1556348
  57. Schaufeli W., Van Dierendonck D. (1994). Burnout, een begrip gemeten. De Nederlandse versie van de Maslach Burnout Inventory (MBI-NL) [Burnout—The measurement of a concept: The Dutch version of the Maslach Burnout Inventory (MBI—NL)]. Gedrag and Gezondheid: Tijdschrift voor Psychologie en Gezondheid 22, 153 – 172.
  58. Sheuli P. (2007). Dynamic time warping (DTW) in small vocabulary word recognition. Masters Abstr. Int. 46.
  59. Shipp A. J., Cole M. S. (2015). Time in individual-level organizational studies: What is it, how is it used, and why isn't it exploited more often? Annu. Rev. Organ. Psychol. Organ. Behav. 2, 237 – 260. doi: doi:10.1146/annurev-orgpsych-032414-111245
  60. Sosnowska J., Hofmans J., Rauthmann J., Wille B. (2021). Personality is dynamic and it matters: the role of personality dynamics in applied contexts. Eur. J. Pers. 35, 418 – 420. doi: doi:10.1177/08902070211022491
  61. Sosnowska J., Kuppens P., De Fruyt F., Hofmans J. (2019). A dynamic systems approach to personality: the personality dynamics (PersDyn) model. Pers. Individ. Dif. 144, 11 – 18. doi: doi:10.1016/j.paid.2019.02.013
  62. Van Buuren S., Groothuis-Oudshoorn K. (2011). mice: Multivariate imputation by chained equations in R. J. Stat. Softw. 45, 1 – 67. doi: doi:10.18637/jss.v045.i03
  63. Van den Heuvel M., Demerouti E., Bakker A. B., Schaufeli W. B. (2013). Adapting to change: The value of change information and meaning-making. J. Vocat. Behav. 83, 11 – 21. doi: doi:10.1016/j.jvb.2013.02.004
  64. Voelkle M. C., Oud J. H. L., Davidov E., Schmidt P. (2012). An SEM approach to continuous time modeling of panel data: Relating authoritarianism and anomia. Psychol. Methods 17, 176 – 192. doi: doi:10.1037/a0027543
  65. Vullinghs J. T., Dóci E. (2020). “A temporal approach to studying organizational leadership,” in Handbook on the Temporal Dynamics of Organizational Behavior (Cheltenham: Edward Elgar Publishing), 251 – 273. doi: doi:10.4337/9781788974387.00025
  66. Walker M. P. (2008). Cognitive consequences of sleep and sleep loss. Sleep Med. 9 (Suppl. 1), S29 – S34. doi: doi:10.1016/S1389-9457(08)70014-5
  67. Woods S. A., Wille B., Wu C. H., Lievens F., De Fruyt F. (2019). The influence of work on personality trait development: The demands-affordances Transactional (DATA) model, an integrative review, and research agenda. J. Vocat. Behav. 110, 258 – 271. doi: doi:10.1016/j.jvb.2018.11.010
  68. Yang H., Yang Y., Xu W., Pang Y. (2017). “An automatic fall detection system based on derivative dynamic time warping,” in Parallel Architecture, Algorithm and Programming (Springer), 427 – 438. doi: doi:10.1007/978-981-10-6442-5_40
  69. Zaheer S., Albert S., Zaheer A. (1999). Time-scale and organizational theory. Acad. Manag. Rev. 24, 725 – 741. doi: doi:10.2307/259351
  70. Zhang Y., Jansen B. J., Spink A. (2009). Time series analysis of a web search engine transaction log. Inf. Process. Manag. 45, 230 – 245. doi: doi:10.1016/j.ipm.2008.07.003
  71. Zhang Z., Tavenard R., Bailly A., Tang X., Tang P., Corpetti T. (2017). Dynamic time warping under limited warping path length. Inf. Sci. 393, 91 – 107. doi: doi:10.1016/j.ins.2017.02.018

Citation

Vossen, J., et al. (2026). Capturing the rhythm of time: introducing Dynamic Time Warping in behavioral research. Frontiers in Organizational Psychology, Volume 4. https://doi.org/
Received
Accepted
Published
Volume
4 - 2026

Copyright

Copyright © 2026 Vossen, Kuijpers and Hofmans.

License: https://creativecommons.org/licenses/by/4.0/

*Correspondence: Evy Kuijpers

Article metrics

Views
0
Downloads
0
Citations
0
Shares
0