Early warning signals for stock market crashes: empirical and analytical insights utilizing nonlinear methods

This study introduces a comprehensive framework grounded in recurrence analysis, a tool of nonlinear dynamics, to detect potential early warning signals (EWS) for imminent phase transitions in ﬁnancial systems, with the primary goal of anticipating severe ﬁnancial crashes. We ﬁrst conduct a simulation experiment to demonstrate that the indicators based on multiplex recurrence networks (MRNs), namely the average mutual information and the average edge overlap, can indicate state transitions in complex systems. Subsequently, we consider the constituent stocks of the China’s and the U.S. stock markets as empirical subjects, and establish MRNs based on multidimensional returns to monitor the nonlinear dynamics of market through the corresponding the indicators and topological structures. Empirical ﬁndings indicate that the primary indicators of MRNs oﬀer valuable insights into signiﬁcant ﬁnancial events or periods of extreme instability. Notably, average mutual information demonstrates promise as an eﬀective EWS for forecasting forthcoming ﬁnancial crashes. An in-depth discussion and elucidation of the theoretical underpinnings for employing indicators of MRNs as EWS, the diﬀerences in indicator eﬀectiveness, and the possible reasons for variations in the performance of the EWS across the two markets are provided. This paper contributes to the ongoing discourse on early warning extreme market volatility, emphasizing the applicability of recurrence analysis in predicting ﬁnancial crashes.


Introduction
Financial crashes, also known as financial crises, are severe and sudden disruptions that have far-reaching economic and social consequences, which typically involve a significant and rapid decline in asset prices, a contraction of credit and liquidity, and a loss of confidence.Since the 2008 global financial crisis, there has been a growing concern to propose models for providing early warning signals of extreme events (crashes), allowing investors and traders to take pre-emptive action to hedge against significant financial losses and to prevent a market collapse.In the field of economics, statistical studies on forecasting financial crises or crashes offer a quantitative comparison of various methods, such as logistic regression.However, these studies have mainly focused on using aggregate macroeconomic data, such as the growth of equity prices and credit levels [1].These macroeconomic data are often low-frequency and non-public, which presents significant limitations in predicting financial collapses.Meanwhile, mainstream economic models have been criticized for their failure to accurately account for the frequency of market crashes or extreme events [2].In the realm of measuring financial crashes or systemic risk, the predominant methods primarily utilize volatility models based on stock market returns or delve into assessing system performance under risk through stress testing.Noteworthy systemic risk metrics encompass the CoVaR, MES, SRISK, IVRVSRI, and TALIS methods [3][4][5][6][7].While these models offer timely and accurate insights into the actual risk conditions of financial markets, their outcomes are contingent on the efficiency of the securities market.Additionally, these models focus more on describing the magnitude of systemic risk rather than providing effective early warning signals for extreme risks.With the interdisciplinary development of nonlinear dynamics, new approaches to economic modeling have emerged, inspired by statistical physics.The field of econophysics has been established with the expectation of better describing the evolutionary behavior of markets, including financial crashes [8,9].Although econophysics has been criticized for using uncritical statistical methods to depict nonexistent phenomena or the unpredictability of human behavior [10,11], there is considerable research value in using a statistical physics perspective to study financial crashes for financial systems to interpret and even predict their evolutionary behavior.
From a view of complex systems, the emergence of financial crashes is associated with imminent transitions in states [12,13], and these transitions are often considered phase transitions of complex dynamical systems.Early warning signals (EWS) generally refer to the observed critical phenomena that involve sudden and often irreversible changes in a system's behavior or state around the tipping points or phase transitions [14][15][16], which are expected to detect and predict critical transitions in complex systems such as ecological, climatological, thermodynamical, and financial systems.Early warning signals are also conceived of as leading indicators that may occur in non-equilibrium dynamics before critical transitions, as they may indicate for a wide class of systems if a critical threshold is approaching [15].
Most EWS are so-called indicators of a loss of resilience [17] such as critical slowing down (CSD), which refers to a slowing down of the system's dynamics, as the system becomes more susceptible to small perturbations and its recovery time after a perturbation increases.CSD can be directly observed in perturbation experiments [16] or be manifested as a pattern of increasing variance or autocorrelation [18,19].Other statistical summary indicators include skewness [20], conditional heteroscedasticity [21], and mean power spectrum at low frequencies (MPS) are also considered potential detectors of CSD.The fluctuation of the time series of these CSD indicators has been widely used in financial systems to detect EWSs of financial crises [22,23].These statistical indicators are often calculated on sliding windows of univariate time series data and tested formally or informally for trends [18].But the effectiveness of these tests varies considerably with data and there is no evidence of the superiority of one indicator over others [24,25].Also, measuring these indicators requires sometimes arbitrary data processing and parameter selection.Lenton et al. pointed out that the power of lag-1 autocorrelation to detect a regime shift is highly uncertain due to the changing methods of data aggregation and detrending, the changing sliding window length, and the change of filtering signal bandwidth [26].Guttal et al. and Diks et al. found that rising volatility might provide an early warning sign of financial crises [27,28].However, Diks et al. also stated that these CSD indicators might fail to deliver real EWSs because a univariate analysis approach may not be appropriate to model a financial time series, given the complexity of financial markets, which typically involve multiple variables and parameters [28].Under the framework of multivariate analysis, some other approaches are used to detect EWSs prior to financial crises such as complex networks and measures of information theory.Squartini et al. affirmed that the topology of an interbank network undergoes major structural change as a crisis suddenly occurs and the topological precursor of this structural change could be used as EWSs of the approaching crisis [29].Works with a similar approach can be found in Saracco et al. and Joseph et al. [30,31], but these studies typically describe observed early warning signals qualitatively rather than quantitatively, which limits their practical application.Building on information theory, Quax et al. introduced the concept of information dissipation length (IDL) as a leading indicator of global instability in dynamical systems [32].They found that the IDL steadily increases towards bankruptcy, and then peaks at the time of bankruptcy.However, the lack of a mechanism for self-organizing systems presents challenges in constructing related models with sufficient predictive power.Gatfaoui and Peretti analyzed information spreading patterns in dynamic temporal networks, where nodes are connected by short-term causality [33].They observed flickering in information spreading before a tipping point occurs.But they found that financial crises occur far from the identified tipping points.Wang proposed a novel interconnected multilayer network framework based on variance decomposition and block aggregation techniques to study the risk correlation between global stock and foreign exchange markets [34].Empirical evidence demonstrated that the French stock market is the largest transmitter in the multilayer network.However, the method only provides warnings for the paths of risk transmission and does not offer accurate predictive tools for the timing of risk occurrence.These previous studies indicate that detecting EWSs is a challenging task, and it is essential to continue developing this field.
While there may be various reasons for the limitations of the existing EWS indicators, one possible explanation is the assumption of weak complexity that dominates mainstream studies' treatment of time series.This approach regards stylized facts such as non-stationarity, non-homogeneity, and long memory in time series data as confounding factors that must be eliminated [35,36], potentially hindering the detection and analysis of complex systems.In traditional time series processing, nonlinear phenomena are often modeled as noise or specific model parameters, such as time-varying parameters involved in time-varying autoregressive models [37] or fractional integration components in ARFIMA models [38,39].Such models have been criticized for limiting dynamic systems to linear or short time scales [40].In multivariate analysis, the common practice of averaging different time series to achieve dimension reduction is also not recommended, as it overlooks significant nonlinear dependencies among variables [41].Therefore, Hasselman proposed the idea of detecting EWSs under the assumption of strong complexity, which involves using developed analytical methods to analyze time series data that allow for the presence of non-stationarity and non-homogeneity to quantify the dynamics of complex systems [40].To achieve this, he constructed recurrence matrices [42,43] for the time series of different state variables of respondents and obtained the corresponding directed weighted networks.Then, he constructed the recurrence network in the phase space of different subsystems into multiple recurrence networks [44] to avoid the use of brute aggregation or dimension reduction.Hasselman found that sudden changes in the key indicators, called geometric resilience loss indicators, of the multiplex recurrence networks (MRNs) could serve as EWSs before respondents were diagnosed with major depression [40].In fact, this was not the first try to apply MRNs to analyzing the evolution of complex systems.Lacasa et al. were the first to introduce the technique of constructing multiplex recurrence networks based on multiple single-layer recurrence networks [45].Similarly, Eroglu et al. used key indicators of MRNs to characterize the evolution of vegetation dynamics systems [46].However, their focus was not on EWSs, but rather on the detection of abrupt changes in these indicators and their correspondence to events.Although Hasselman intended to promote this technique for detecting EWS, he was more focused on its application in preventing human diseases or psychopathology, which are based on relatively low-frequency research data [40].Additionally, the study did not provide a clear scheme for quantifying the peaks of the indicators of the MRNs.Considering the strong complexity of financial systems and drawing inspiration from the aforementioned technique based on the strong complexity assumption, this study aims to employ MRNs to capture the structural similarity of financial complex systems.And the multidimensional high-frequency financial returns of constituent stocks in the China's and U.S. stock markets are used as the main empirical objects.Additionally, the study will propose quantitative criteria for effectively detecting sudden changes in key MRN indicators.
To the best of our knowledge, this study represents the first attempt to apply indicators of multiplex recurrence networks in the early warning of extreme volatility or financial crashes in financial systems.The aim of this paper is to provide a quantitative analytical tool for examining changes in the state of complex financial systems, rather than qualitatively describing their evolutionary processes.It offers a perspective on considering financial issues from the perspective of complex system, emphasizing the necessity of preserving typical characteristics of financial time series under strong complexity assumptions before conducting modelling analysis.This approach can help financial practitioners enhance their capabilities of risk management, timely avoid extreme losses to some extent.The study aims to answer two main questions: did any financial crash or extreme event occur when the indicators of the multiplex recurrence network change, and can these indicators serve as quantifiable early warning signals of an approaching crash?Our empirical results suggest that the answer to both questions is affirmative, achieving the goal of developing financial risk management from an econophysics perspective.The remaining sections are organized as follows: Sect. 2 will comprehensively introduce the process of constructing multiplex recurrence networks and the geometric resilience loss indicators, incorporating the basic concept of recurrence quantification analysis (RQA).Section 3 will propose a methodological framework for detecting EWS prior to a financial crash and introduce a quantitative algorithm for determining whether the indicators have undergone a sudden change.Section 4 conducts a simple simulation experiment to demonstrate that MRN and its indicators are suitable for identifying different states in the evolution of complex systems with noise, such as financial complex systems.Section 5 will provide a detailed account of the empirical analysis, including the basic results and a comparative analysis of the proposed model with the benchmark.Finally, Sect.6 provides concluding remarks and a discussion of the findings.

Recurrence plots and recurrence quantification analysis
Eckmann et al. first proposed the concept of recurrence plots (RP), which they believed was a fundamental property of all dynamic systems [47].RP is a two-dimensional visualization tool developed based on this property.Over the past two decades, RP has developed into a nonlinear method for describing complex dynamics [42].
RP is a graphical representation of the recursive states of a dynamic system in its mdimensional phase space.A pairwise measurement is performed on all phase space vectors x i (i = 1, . . ., N, x i ∈ m ) regarding their distances to determine whether they are close: where (•) denotes the Heaviside function, while ε represents a threshold for d( x i , x j ), and d( x i , x j ) is the distance between the vectors [42].The distance measure d( x i , x j ) can be determined using various methods, such as spatial distance, string metrics, or local rank order [42,48].In most cases, spatial distance is considered to be the Euclidean norm, i.e., d( x i , x j ) = x ix j .Denote R as the binary recurrence matrix and consider R i,j as the elements in the matrix.R i,j is set to 1 if the distance x ix j is less than ε, and 0 otherwise.The phase space trajectory can be reconstructed from the time series {u i } N i=1 by time-delay embedding [49]: where m represents the embedding dimension and τ represents the time delay, and their appropriate values can be chosen according to [50].In empirical studies, ε is usually chosen to yield a recurrence rate of 0.05, or as 0.05 times the standard deviation of the original data [42,46].Clearly, the RP has a diagonal line representing the recursion of each point with itself, and if spatial distance is used as the criterion for recursion, the RP is also symmetric.The small-scale features of the RP can be observed using the diagonal and vertical lines, and Zbilut and Webber introduced Recurrence Quantification Analysis (RQA), a quantitative description of the RP based on these line structures [51].It defines measures of diagonal line segments, recurrence rate, average length of diagonal structures, entropy, and more [52], offering insights into the nonlinear dynamics of the analyzed system.However, RQA focuses on identifying recurrence patterns in the time series, which may not capture the full complexity of the dependence between variables.The empirical section of the study will provide evidence that RQA may have limitations in describing system transitions and changes in underlying dynamics and may not offer an intuitive visualization of higher-order interactions between variables in the system.

Multiplex recurrence network
Multiplex recurrence networks (MRN) provide a framework for investigating the temporal structure of multivariate time series in a complex dynamical system and allows for more flexibility in representing their interaction relationship [40], which have been developed by horizontal visibility graphs [45] and recurrence networks [46].Specifically, an  1) and the corresponding adjacency matrix A [k] = a [k]  ij can be obtained, where if the ith and the jth vertices in the kth layer are connected, and 0 otherwise.The giant adjacency matrix that describes the multiplex network can then be expressed as: A [1]  [2] . . .
where I N is the identity matrix of size N .In practice, the multiplex recurrence network is typically not constructed using the giant NM × NM matrix, but rather by representing M-layer recurrence networks as vertices connected by their interdependence.Hence, the MRN will be a weighted network of size M × M.This projection of multilayer networks into single-layer networks has been shown to be a superior and efficient approach compared to other methods that require symbolic processing of time series [40,45,46].A commonly used measure to reflect the non-linear dependence between different layers is the interlayer mutual information [45].The interlayer mutual information I α,β represents the correlations between the degrees of the same node at layers α and β, where α, β = 1, . . ., M; α = β.The detailed definition is defined as: P k [α] , k [β] ln P(k [α] , k [β] ) P(k [α] )P(k [β] ) , where P(k [α] ) and P(k [β] ) are the degree distributions of recurrence networks at layer α and β, respectively, and P(k [α] , k [β] ) is the joint distribution of the vertices that have degree k [α]  at layer α and degree k [β] at layer β.

The indicators of MRN
The indicators of MRN provide a quantification tool to characterize information shared across all layers of the underlying high-dimensional system.The averaged mutual information is defined as: which is considered as an important measure of typical information flow between the multivariate time series [45,46].Another common measure to capture the overall coherence of the original timeseries in the MRN is the Average Edge Overlap ω.It should be noted that the definition of average edge overlap used here differs subtly from that used by Lacasa et al.and Eroglu et al. [45,46].Their average edge overlap represents the average number of identical edges across all layers of the multiplex network, while we first calculate the proportion of edges shared between any two vertices in each layer-pair and then calculate the average value across all layer-pairs, which is consistent with Hasselman [40].Then the Average Edge Overlap ω could be defined as: It is also a global measure of coherence between different layers of MRN, and, together with the averaged mutual information, forms the most important quantitative indicators of MRN to detect phase transitions in multidimensional time series systems.When these two indicators suddenly increase, it indicates a sudden increase in the similarity between different dimensional variables in the system.This may signify the emergence or impending emergence of certain system behaviors, thus providing a theoretical basis for its potential use as an EWSs.
Using sample data with dimension M = 3 and length N = 20 as an example, Fig. 1 demonstrates the essential steps in constructing the MRN.For the single-dimension time series, the interlayer Recurrence Networks(RNs) of the MRN are individually constructed, with their topology displayed in subplot (b) of Fig. 1 when the recurrence rate is set to 0.05.Subsequently, based on Eq. ( 4), the interlayer mutual information between the three RNs is computed, and a fully connected, undirected, weighted network with three nodes is established using the interlayer MI as edge weights, as depicted in subfigure (c).This schematic diagram highlights that no supplementary assumptions are necessary for the generation process or model of the time series during the construction of the MRN.Additionally, there are no stringent requirements concerning data sample length or addressing issues related to non-stationarity and autocorrelation.Moreover, when calculating mutual information, the similarity of the degree distribution of the paired RNs is considered after converting the series into RNs, rather than relying on the distinct state values of the original time series.This approach quantifies the inter-layer information flow of the multiple networks from the topology of the recurrence network, thereby reflecting the system's characteristic behavior with enhanced robustness.

Detection of EWSs in the financial system
For the indicators of MRN, several studies have demonstrated through simulations and empirical analyses that the peaks in their sequences can reveal phase transitions in various systems, such as financial instability periods [45], climate transitions, or human impact in ecological systems [46], and shifts in psychological states [40].This implies that the absolute size of the indicators is not as meaningful as the sudden and significant changes in these indicators.However, these peaks are usually obtained through visual inspection rather than measured by quantitative standards, which may raise doubts about the credibility of the results.This study introduces a changepoint detection algorithm with the aim of determining the quantity and location of indicator peaks, which will lay the foundation for detecting EWSs.Finally, a general framework for monitoring phase transitions in financial markets and examining potential EWSs before financial crises will be presented.

Detection of changepoints
The test for multiple changepoints is a general method for detecting changepoints in time series, which has an advantage over other tests for structural changes in that it does not require assumptions about the model underlying the original series.This is particularly suitable for MRN indicators, as the distribution or generative model of the indicators is unknown.Assume that there is an ordered data series, y 1:n = (y 1 , y 2 , . . ., y n ), and there exists a changepoint γ , γ ∈ {1, . . ., n -1}, such that {y 1 , . . ., y γ } and {y γ +1 , . . ., y n } are expected to be essentially different.Assume that there are p changepoints in the sequence, with their positions represented by γ 1:p = (γ 1 , . . ., γ p ), where each changepoint is represented by an integer between 1 and n -1.Define γ 0 = 0 and γ p+1 = n, and assume that the changepoints are ordered, such that γ e < γ f only when e < f .The p changepoints will divide the data into p + 1 segments, with the eth segment containing the subsequence y (p e-1 +1):p e .Each segment will be characterized by a set of parameters, represented as {θ e , φ e }, where φ e is a set of (possibly empty) disturbance parameters, and θ e is the set of target parameters.Typically, the number of segments needed to represent the data, i.e., the number of changepoints, will be detected and the corresponding parameters will be estimated.
In the test of multiple changepoints, the detection procedure can be converted to an estimation problem of parameters that minimize the following equation: where C is the cost function for the segments, such as negative log-likelihood, and μf (p)(μ > 0) is a penalty term to prevent overfitting, which increases with p, since for most cost functions, adding a changepoint always reduces the total cost.The minimization of Eq. ( 8) involves two key issues: finding the optimal sequence segmentation method and determining the penalty term.For sequence segmentation, there are three common algorithms: binary segmentation [53], segment neighborhoods [54], and the recently proposed pruned exact linear time (PELT) [55].Binary segmentation first performs a single changepoint test on the entire data.If a changepoint is found, the data is split at that point until it cannot be further divided.It is fast, but its speed may come at the expense of the accuracy of the obtained changepoints [55].The segment neighborhoods algorithm was proposed by Auger and Lawrence [54].The algorithm precisely minimizes Eq. ( 8) using dynamic programming techniques, but its computational complexity is much higher than that of binary segmentation.The PELT algorithm balances the trade-off between speed and accuracy well.It provides an accurate segmentation similar to the segment neighborhoods algorithm, but it greatly reduces computational complexity by using dynamic programming and pruning.If f (p) in Eq. ( 8) is linear, the minimization problem can be expressed as follows: In the iteration of the PELT algorithm, the above equation can be represented as: The so-called pruning means that if there exists a constant K such that for all ζ < t < n: ),then at some future time n > t, ζ cannot be the last changepoint before T.
For the problem of selecting a penalty term, extensive research has been conducted by many authors.Commonly used penalty terms in literature include μ = 2q (Akaike's information criterion [56]); μ = q log n (Schwarz's information criterion [57]; and μ = 2q log log n [58], where q represents the number of additional parameters involved in adding a changepoint.More complex penalty methods, such as modified Bayesian information criterion (mBIC [59]), take into account the length of the segments.Although these common choices have good theoretical properties, they rely on assumptions about the data generation process.Unfortunately, modeling assumptions associated with a particular criterion may be violated in practice [60].Haynes et al. proposed a new algorithm -Changepoints for a Range of Penalties (CROPS), which utilizes the simple relationship between the solutions to the penalty-minimization problem and the constraintminimization problem to find a set of different penalty values [61].Each penalty value corresponds to a different segmentation or excludes certain numbers of changepoints because no best segmentation that minimizes the penalty cost can be found.In practical applications, the combination algorithm of PELT and CROPS has been shown to have good performance for the detection of multiple changepoints in time series [62,63].It does not require strict model assumptions about the time series itself and has strong applicability.Therefore, in this paper, the PELT-CROPS algorithm is employed to detect multiple changepoints in the indicators of MRN, with technical support provided with the "changepoint" package in R [64].It is worth noting that when applying the above algorithm to the indicator sequences of MRNs, the detected changepoints in the indicators are not entirely equivalent to the local peaks of the indicators.In fact, the changepoints here correspond to the moment just before the occurrence of the indicator's local peak or local valley.If the first part of the empirical evidence can demonstrate a one-to-one correspondence between the local peaks of the indicators and the periods of financial extreme volatility, then the changepoints of the indicators can serve as potential early warning signals.Therefore, the focus of the second part of the empirical analysis will be on observing whether the changepoints in the indicators occur before the actual onset of risks, and whether most risks happen within the period alerted by two adjacent changepoints.

A framework for detecting EWSs using MRNs
The steps for building a general framework for monitoring EWSs in financial markets can be summarized as follows: (a) As financial crises often manifest as significant and widespread declines in stock prices, assume there are M representative constituent stocks in the market and treat their return data as time series variables for the M dimensions of the system.
(b) Determine an appropriate time window length and sliding step size, construct a recurrence network for each dimension's return series within each time window; calculate the inter-layer mutual information between each pair of recurrence networks; construct a multiplex recurrence network with M nodes and consider the inter-layer mutual information as edge weights.
(c) Calculate the average mutual information and average edge overlap for all MRNs corresponding to each time window, and thus obtain the series of the indicators.
(d) Apply the method of changepoint detection to series of these two indicators.The detected changepoints only indicate that the segment before and after the changepoint have significant differences, and the values after the changepoint may be significantly greater or smaller than the changepoint.Previous empirical results have shown that only sudden increases in indicator values correspond to system phase transitions.Therefore, this study considers only upward-trending changepoints as potential EWSs.
(e) Treat the moments corresponding to extreme values of market index returns as the actual times of financial crises.If the EWSs obtained in step (d) precede these moments, it can be demonstrated that the general framework to detect EWSs is effective.

Simulation experiment
Financial return series often contain a large amount of noise.Before applying the method based on MRNs to actual market data, we aim to demonstrate through a simulation experiment that the indicators of MRNs can still distinguish different states of complex systems containing varying degrees of noise, in order to mitigate the impact of noise on the results in the final empirical analysis.We consider Coupled Map Lattices (CMLs) to generate time series with nonlinear correlations, in an effort to closely replicate the non-independence of actual return series.CMLs are simple spatiotemporal chaotic models, and due to their high-dimensional dynamical systems, they are widely used in complex spatiotemporal dynamics modeling.Generally, their form is: where x [κ]  t can be understood as the value of the κth series at time t (κ = 1, 2, . . ., M; M is the dimension of the multidimensional time series), and h κ t represents the interaction generated by the elements of other time series on the element of the κth series at time t.The first term on the right side of the equation represents the internal chaotic dynamics mechanism determined by the nonlinear mapping function f (x), while the second term represents the mutual coupling effect produced by the coupling parameter ζ (0 < ζ < 1).Generally, CMLs have three types of coupling: local or direct-neighbor coupling, where ).In this experiment, following the practice of Lacasa et al. [45], Eroglu et al. [46], and [71], we treat the Mdimensional time series as M points on a ring model.As such, the dynamic evolution of the state of each site x [κ] is determined by the internal chaotic evolution and the average coupling effect between external neighboring sites, which is a form of direct-neighbor coupling, given by: As ζ varies, the system is trapped in different attractors, thereby delineating the system's various dynamical phases.Hence, we can observe whether the indicators of the MRNs established based on multidimensional simulated series can identify these distinct phases.We select the classic logistic mapping function f (x) = 4x(1x) as the internal chaotic dynamic mechanism, assuming the system has a dimension of M = 5.The coupling parameter ζ is set within the range [0, 0.4] and varies in increments of = 0.005.By iterating 1000 times, we obtain a simulation series with a dimension of 5 and a length of 1000.
In each experiment, Gaussian white noise (with a mean of 0 and a standard deviation of 0.05, to ensure the magnitude of noise standard deviation is consistent with that of the standard deviation in the CML sequences) with the same signal-to-noise ratio (SNR) is added to the five simulated series of the CML system.A1 and  A2, which specify the constituent stocks.All the data are obtained from Wind.Returns within this study are characterized as the logarithmic disparity between the closing prices of two successive observations, expressed as r t = log p t -log p t-1 .To account for market micro-noise and the "often but not too often" sampling criterion, this study employs the commonly used 5-minute sampling frequency for returns.

RQA's limitation for identifying phase transition
Prior to the construction of MRNs for the stock market, it is crucial to distinguish the differences between MRNs and recurrence quantification analysis (RQA) of multidimensional time series.This study assumes that the underlying dynamical system of individual stock returns is unidimensional, thereby negating the necessity for phase space reconstruction of the original return series when establishing MRNs or conducting multidimensional RQA.This assumption aims to guarantee equal data length across various dimensions, as the parameters involved in phase space reconstruction, specifically embedding dimensions and time delay, diverge for each dimensional series.Additionally, the number of individual stocks is sufficiently large to partially restore the dynamic space of the system.For instance, during the RQA of multidimensional time series for China's stock market, each temporal point within the system is epitomized by 56-dimensional returns derived from its 56 constituent stocks.Given a time series length of N , an N × N distance matrix is computed, with each Euclidean distance predicated on the data from M = 56 dimensions.After setting the threshold ε to achieve a recurrence rate of 0.05, Fig. 3 shows the recurrence networks with a spiral layout [67] constructed by the daily returns for each year from 2014 to 2020 and all daily returns from 2014 to 2020, respectively, which reveals the order of the date nodes and their connectivity.Based on the definition of recurrence, the coordinates in the state space can be considered as the attractor region of the system when they are close in distance, and the nodes with higher degree in the recurrence network are likely to be the so-called attractors.Phase extraction, referring to the identification of attractor regions in phase space, is carried out on the created weighted recurrence network.This process involves locating the node with the highest degree, then finding the node connected to the initially identified node and continuing to identify the highest degree node among those not connected to the first identified node.The predetermined number of phases dictates when this procedure concludes.An isolated node signifies the absence of state recurrence, while nodes failing to satisfy the phase extraction procedure are labeled as "others." To simplify the differentiation of financial periods, it is presumed that the system experiences only two phases during its evolution.Consequently, the nodes in all subgraphs in Fig. 3 are categorized into four groups: "no recurrence, " "phase 1, " "phase 2, " and "others, " each represented by distinct colors.Nevertheless, these four states cannot correspond to the actual periods of financial system evolution, as no specific variable defines market evolution.Moreover, when extensive historical data is present, the Recurrence Network (RN) plot struggles to clearly depict phase shifts, as illustrated in the 8th subplot.As a result, Recurrence Quantification Analysis (RQA) findings are challenging to interpret and are subject to uncertainties contingent upon the number of pre-defined phases and the time series length.Therefore, despite RQA's relative maturity and capacity to describe system dynamics to some extent, it remains arduous to detect extreme financial crises or provide early warnings effectively.

Revealing unstable financial periods through MRN indicators
In the empirical analysis, a fixed time window of 5 trading days is used to investigate whether the MRN indicators can provide insights into financial extreme events (both positive and negative) or periods of financial instability.MRN is built based on the 5-minute multidimensional return series within each time window, and the corresponding average mutual information and average edge overlap are calculated using Eq. ( 4) and Eq.(5) to

Figure 4 The time course of the indicators calculated for the Multiplex Recurrence Network based on returns in
China' s stock market using a sliding window of 5 trading days: average mutual information and average edge overlap.The local peaks are marked in different colors, and the legend on the right lists in detail the time intervals corresponding to the local peaks and the financial extreme events that occurred in the China's stock market during these intervals obtain the indicator series {I i } φ i=1 and {ω i } φ i=1 , respectively.Here, φ = l 5 , where l is the length of the historical window, and φ denotes the number of non-overlapping unit time windows that can be derived from the historical window.The segmentation unit of 5 trading days or 22 trading days is typically used in such studies, corresponding to the trading length of one week and one month, respectively.Given that shorter time windows provide higher accuracy when testing whether sudden changes in indicators correspond to financial extreme events, this study finally adopts a unit time window of 5 trading days.In Fig. 4, the time course of MRN indicators based on stock returns in China's stock market is presented.It is evident from the figure that the average mutual information series exhibits more volatility than the average edge overlap series, as it has more peaks, but these peaks are not as pronounced as those of the average edge overlap.The average edge overlap, on the other hand, has a relatively stable trend, with visible spikes during its peaks.In this study, the nine unique peaks in the average mutual information and the four distinct peaks in the average edge overlap are labeled and further examined to confirm whether extreme financial events occurred in the corresponding time windows.The findings indicate that all the peaks in the series of average mutual information correspond to periods of financial instability or crises within the historical window, and these events are not ordinary market fluctuations but rather significant shocks that have had far-reaching and wide-ranging impacts on the market and are etched in the history of China's stock market.The negative events revealed by the indicators include the stock market crashes in mid-to-late June and mid-to-late August 2015, the market collapse caused by the outbreak of the COVID-19 in China in early February 2020, and the linkage effect on China's stock market caused by the successive circuit breakers triggered by the U.S. stock market in mid-March 2020.The positive event revealed by the indicators includes the new high of the SSE Composite In-Figure 5 The time course of the indicators calculated for the Multiplex Recurrence Network based on returns in U.S. stock market using a sliding window of 5 trading days: average mutual information and average edge overlap.The local peaks are marked in different colors, and the legend on the right lists in detail the time intervals corresponding to the local peaks and the financial extreme events that occurred in the U.S. stock market during these intervals dex at the end of 2014.Among the peaks of the average edge overlap, three are the same as those of the average mutual information, revealing the same three periods of financial instability, but ignoring other equally significant financial extreme events.The unique peak in the average edge overlap corresponds to mid-to-late July 2015, when China's stock market experienced a thousand-stock limit-down, marking the second stage of the so-called "stock market disaster" in 2015.
Performing the same analysis on the historical returns of the U.S. stock market, Fig. 5 illustrates the correspondence between local peaks in the indicators and historical extreme financial events in the US.Similarly, most of the local peaks in the average mutual information correspond to extreme market shocks, such as the negative impact of Brexit on the US stock market in late June 2016, the huge rebound in the market after Trump's inauguration in early November 2016, and the multiple circuit breakers triggered by the outbreak of COVID-19 in the US stock market in mid-March 2020.However, compared to the trend of the average edge overlap in Fig. 4, the time course of average edge overlap in Fig. 5 has more sharp local peaks and flatter values in other periods.Only two of these local peaks actually correspond to periods of extreme financial events, which are also revealed by the average mutual information.The remaining local peaks correspond to periods where either no significant financial events occurred or only normal market fluctuations caused by the uncertainty of Brexit and the new presidential election in 2016, which were not extreme.Interestingly, the average edge overlap also fails to identify the rare financial event of the U.S. stock market experiencing four circuit breakers in mid-March 2020.
By examining the performance of these two indicators in two typical stock markets, it can be concluded that both the average mutual information and the average edge overlap can reveal to some extent the periods of financial instability in history.This is because sudden changes in indicators indicate that the global similarity between multidimensional returns in the market has reached a maximum within a period, and the system is likely to experience emergence due to the convergent behavior of individual stocks, leading to a market crash or strong rebound.Furthermore, the average mutual information is a more accurate measure than the average edge overlap in capturing extreme events.This is because edge overlap measures the overlap of edges between any two RNs with the same nodes, which is essentially similar to linear measures such as correlation coefficients, while mutual information involves the degree distribution of RNs and is a non-linear measure, more suitable for capturing the non-linear dependence between inter-layer RNs.Moreover, compared to mature stock markets such as the U.S. stock market, the average mutual information and average edge overlap perform better in indicating periods of financial instability in emerging markets such as China's stock market.This is evidenced by the fact that the local peaks of the average mutual information are more obvious in China's stock market and the accuracy of the indication of the peaks of these two indicators is higher.This may be due to the relatively weaker long-memory and stronger randomness of returns in the U.S. stock market, which weakens the difference in the topological structure of RNs between periods of financial stability and instability.Finally, it can be found that the frequency of negative extreme events is higher than that of positive extreme events, which is consistent with previous research results [68,69].It is also worth noting that the time course of the average mutual information in Fig. 5 raises an important question: is it too subjective to rely solely on the visual identification of local peaks?This question echoes one of the motivations of this paper, which is to propose a quantification too to systematically identify the local peaks of indicators.This will be explained in detail in Sect.5.5.

Revealing unstable financial periods through MRN topology
The introduction highlighted one of the benefits of MRN, which is avoiding the rough aggregation of original multidimensional series for dimensionality reduction.Additionally, the topological structure of MRN enables more in-depth analysis by reverting to the original dimensions.To investigate differences in the topological structures of MRNs corresponding to various periods, this study seeks to employ the maximum spanning tree (MST) algorithm.Although the minimum spanning tree algorithm is a common algorithm for analyzing network topology, its goal is to find a tree with the minimum sum of edge weights in a weighted undirected connected network, where a tree in a graph contains υ vertices of the network but only includes υ -1 edges to connect all vertices.This algorithm is typically used to allocate resources under a fixed budget, where the weight of the edges emphasizes loss or cost.Conversely, the maximum spanning tree algorithm aims to find a tree that generates the maximum sum of edge weights, which is more relevant to the focus of this study.In this paper, the weight of the MRN is determined by the value of inter-layer mutual information.The larger the weight between two vertices, the closer the connection between layers.By implementing the maximum spanning tree algorithm on the MRN, the structure of the tree can determine the relative importance of vertices when the mutual information value reaches its local maximum, reflecting clues to finding the "central" stocks that have high similarity with most individual stocks.The evolution of this "central" structure is believed to have some connection with the dynamics of the financial system.
In the previous section, the peaks of the series of average mutual information revealed 9 unstable financial periods in China's stock market and 8 unstable financial periods in Figure 6 The Maximum Spanning Trees (MSTs) of the corresponding MRNs in China' s stock market.The MSTs on the left of the time horizon belong to the so-called period of financial instability, while those on the right belong to the period of financial stability.Each constituent stock is assigned the same color in all the networks, while the size of a node is proportional to its degree Figure 7 The Maximum Spanning Trees (MSTs) of the corresponding MRNs in the U.S. stock market.The MSTs on the left of the time horizon belong to the so-called period of financial instability, while the MSTs on the right belong to the period of financial stability.Each constituent stock is assigned the same color in all the networks, while the size of a node is proportional to its degree the U.S. stock market.Figures 6 and 7 respectively show the maximum spanning trees of the MRNs corresponding to unstable and stable periods in these two markets, where the stable periods were randomly selected from the timeline with the same number as unstable periods.Figure 6 shows that the maximum spanning tree of the 9 MRNs on the left exhibits a multi-hub structure, with several (greater than or equal to 3) vertices having high degrees.This also implies that the degree of the maximum-degree vertex is unlikely to exceed one-third of the total degree, and the maximum-degree vertex during unstable periods changes over time.In contrast, the maximum spanning tree of the MRN corresponding to the relatively stable periods on the right usually has only 1-2 hubs, indicating that the degree of the maximum-degree vertex is likely to exceed one-third of the total degree, and the hubs are relatively stable and do not change over time.Observing the structures of the maximum spanning tree from all sliding time windows, it is notable that sh500109 (Guizhou Maotai) is the vertex with the maximum degree in most trees, while in some periods, sh603288 (Haitian Flavoring) holds this position.Few other stocks act as the "central" nodes.As the company with the highest stock price in the Shanghai Stock Exchange during 2014-2020, the influence of the price fluctuations of Guizhou Maotai is more extensive than that of other stocks.Similarly, Haitian Flavoring ranks among the top three in the weighting of the Shanghai Consumer Index, with extensive brand recognition and market share.Therefore, it is understandable that these two stocks are connected to most other stocks as the largest hub in most periods of market evolution.However, when the system enters an unstable period, the topological structure determined by market capitalization or market influence breaks down, and more hubs emerge.During these periods, the vertex with the maximum degree is no longer Guizhou Maotai or Haitian Flavoring, but is replaced by sh600808 (China Petroleum & Chemical Corporation Guizhou Branch), sh601179 (China Western Power), sh601808 (China Oilfield Services Ltd.), and other stocks that do not have outstanding market capitalization or market share.This phenomenon indicates that when extreme financial events occur, the original order of the market is disrupted, leading to a disorderly state within the system.At this time, the similarity distribution between different stock returns is more uniform, which can be understood as the emergence of irrational behavior induced by extreme financial events in the group.The market shows a large number of similar investment behaviors and preferences, thereby intensifying market price fluctuations and providing a theoretical basis for emergent behaviors in the system.
Figure 7 illustrates the corresponding results for the U.S. stock market, exhibiting a similar phenomenon to Fig. 6 where the MST of the unstable period mostly displays a multihub structure, while the MST of the stable period mainly has 1-2 hubs.In contrast to Fig. 6, the degree distribution in the MST of the unstable period is more dispersed, which suggests that the sudden changes in the entire system are not driven by the behavior of a few individual stocks, but by the similar behavior of most constituent stocks in the system.The hubs in the MST of the stable period also change over time: from March to August 2016, the hubs were WEC Energy Group, Inc. (WEC) and PPL Corporation (PPL), indicating the energy industry's significant position in the system during this period.From February 2017 to July 2019, the hubs were W.W. Grainger, Inc. (GWW) and Stanley Black & Decker, Inc. (SWK), both of which are renowned industrial supply companies in the U.S., signifying that the industry was the primary direction of the U.S. stock market during this period.In February 2020, before the COVID-19 outbreak in the U.S., Coca-Cola Company had a strong dependence relationship with most S&P 500 constituent stocks, but in October, after the outbreak, the constituent stock that had a significant impact on the market was Humana Inc. (HUM), a company that provides medical insurance and health management services primarily for people aged 65 and older.This indicates that in the absence of extreme financial events, the MST topology of the MRN can roughly describe the evolution process of the U.S. stock market.Furthermore, it reveals that compared to emerging markets, the maturity of the U.S. stock market is reflected in the fact that the constituent stocks that dominate market behavior are time-varying.
Based on the analysis above, a straightforward rule is devised to roughly categorize the MSTs according to their topology and infer the unstable periods of the financial system.Specifically, vertices with degrees surpassing one-third of the total degrees in the maximum spanning tree are deemed central vertices.For China's stock market, if: a) one or more central vertices exist in the MST, and the central vertex is either sh500109 or sh603288, the corresponding period is considered financially stable without extreme risks; b) one or more central vertices exist in the MST, and the central vertex is neither sh500109 nor sh603288, the corresponding period is considered uncertain, with potential risks; c) no central vertices exist in the MST, the corresponding period is considered financially unstable, with heightened risks.Since the frequency of stocks becoming central vertices is not markedly distinct during stable periods of the U.S. stock market, the rule for the market is as follows: a) if one or more central vertices exist in the MST, the corresponding period is considered financially stable without extreme risks; b) if no central vertex is present, the corresponding period is deemed a period of financial instability with substantial risk.Figure 8 presents the results of the MST classification of MRNs in different periods based on the aforementioned rules, as well as the inference results of financially unstable periods.This extrapolation categorizes periods of uncertainty and risk as being clustered as periods of financial instability.Most of these periods contain moments when the average mutual information peaks, which demonstrates that the topology of the MRN is capable of describing the dynamical evolution of the financial system to a certain extent.However, this study only proposes a rough classification scheme based on the MST structure of most MRNs, and its accuracy in revealing real financial extreme events still needs to be improved compared to the peaks of average mutual information.For example, under this rule, the period corresponding to the first MST in Fig. 7 is considered to have no extreme risks, but it actually experienced extreme events.Therefore, when considering tools that may serve as EWS, this study focuses on the primary MRN indicators.

Early warning signals indicated by changepoints of MRN indicators
Based on the first question proposed in this article, Sects.5.3 and 5.4 provide affirmative answers from two perspectives, respectively.That is, during financial extreme events, the indicators or topological structure of the MRN undergo changes, and the indicators of the MRN, especially the average mutual information, provide clearer and more accurate indications for periods of financial instability.However, the purpose of this study is not limited to this, as the present work is more like the result of an in-sample test, and the practical application of the MRN has not been realized yet.The second question proposed focuses on whether these MRN indicators can be employed as potential EWSs to timely warn against future risks.This section will analyze and discuss this question.
The analysis in the previous section indicates a one-to-one correspondence between sudden changes in MRN indicators and financial extreme events.However, the so-called peaks are obtained from observation rather than through some quantitative standards.Additionally, because the unit time window used is 5 trading days, even if it can be demonstrated that an event did occur during this period, it cannot be confirmed whether the sudden change of the indicator occurred before or after the occurrence of the events.If it is the former, the likelihood of using MRN indicators as EWSs is significantly reduced.The key to verifying whether MRN indicators have EWSs functionality lies in two steps.First, constructing MRNs for a smaller time scale, such as one trading day.Considering that there are fewer high-frequency returns in a day and that the nonlinear correlation changes between constituent stocks may show signs of change in a previous period, a rolling window approach with a fixed window length of 5 trading days and a sliding step size of 1 day will be used.Calculate the MRN indicators for each rolling window and obtain their time series of {I i } φ i=1 and {ω i } φ i=1 , where φ = l -4.Using the data from the U.S. stock market as an example, I 1 represents the average mutual information for January 11, 2016, which is based on the 5-minute returns from January 5, 2016, to January 11, 2016.Secondly, appropriate quantitative tools will be used to detect sudden changes in the obtained series of indicators.The PELT-CROPS algorithm mentioned in Sect. 2 will be employed to find the changepoints.The 99.5th percentiles (positive and negative) of the returns of the market indices (SSE Composite Index and S&P 500 Index) in the historical window are regarded as the thresholds.When positive returns exceed the threshold or negative returns are less than the threshold, it is considered that an extreme financial event occurred on that day.In particular, the timing of a crash in the empirical work is defined as the moment when negative returns exceed the certain threshold.This study will, therefore, focus on examining the changepoints of the rolling window MRN indicators to provide early warning of extreme financial events, particularly those that are negative in nature.
For {I i } φ i=1 and {ω i } φ i=1 , PELT-CROPS traverses a certain range of penalty terms to determine a relatively optimal segmentation scheme for the series.Figure 9 displays a diagnostic graph based on different indicator series in two markets.The graph depicts the trend of penalty values as the number of changepoints increases.When the curve becomes smooth after a certain point, the number of changepoints corresponding to that point is considered to be the relatively optimal choice.Therefore, the optimal number of changepoints for {I i }  When the curve becomes smooth after a certain point, the number of changepoints corresponding to that point is considered to be the relatively optimal choice changepoint, indicating that a sudden change will occur after the changepoint, and it is this change that makes adjacent segments fundamentally different.In terms of the construction of average mutual information and average edge overlap, larger values of them indicate higher similarity between layers in the MRN from a global perspective.The results of the previous two sections also suggest that the sudden increase in similarity corresponds to the emergent behavior of the system.Therefore, for all detected changepoints, if the mean value of the segments after the changepoint is higher than that of the segment where the changepoint is located, it is believed that the changepoint releases a signal indicating that the indicator will undergo an upward mutation, and a financial extreme event is likely to occur in the period after this signal.Such changepoints are considered potential EWSs in this paper, while the remaining changepoints are not within the scope of the main analysis.
Figure 10 displays the MRN indicators of rolling windows in China's stock market.The red dots in the figure are identified as EWSs, while the blue dots represent actual extreme returns.The first segment adjacent to the red dot is considered as the predicted period of financial instability.From the figure, it can be seen that EWSs based on average mutual information have a good early warning effect on extreme financial events, and only two extreme events were not predicted in advance: the circuit breaker that occurred on January 4, 2016, the first trading day of 2016 and the first day after the New Year holiday.This may be because the MRN based on data from the end of 2015 did not capture the evolution of the system in a timely manner due to the holiday.The second event, caused by the escalation of the US-China trade war on February 22, 2019, coincided with one of the changepoints of interest.On the other hand, with regard to the average edge overlap, the predicted period of instability is short-lived during the time when extreme events occur frequently.A significant number of extreme events fall outside the predicted period, and only when the predicted period of instability is longer can sparsely-distributed extreme events be included.
Figure 11 presents the empirical results in the U.S. market.When the changepoints of the average mutual information are used as EWSs, there are five extreme events that were not correctly predicted, while the changepoints of the average edge overlap completely lost the early warning ability for extreme financial events.Overall, the changepoints of the average mutual information have higher potential as EWSs for the phase transitions The ellipse on the graph zooms in on the trend of an indicator at a certain time, serving as a schematic illustration of how the indicator can be used as an EWS in practical applications.The three colors of the triangle indicate the levels at which the average mutual information of the latest date may be located, and only the case corresponding to the red triangle indicates that the average mutual information of the previous day can be considered as a changepoint.Accordingly, the latest date and a period thereafter will be considered an unstable period with the possibility of extreme events  of financial systems, while the average edge overlap does not appear to be a reliable tool.The possible reasons for the difference in effectiveness between these two indicators have been discussed in Sect.5.3.Table 2 lists the accuracy of predicting extreme events using EWSs, which is the probability of correctly predicting actual extreme returns, and the average lead time of EWSs detected in the series of the average mutual information in both China's and the U.S. stock markets.The distribution of lead times of EWSs in both markets is illustrated in Fig. 12.The changepoints of the average mutual information have better performance in predicting extreme events in China's stock market than in the US stock market, in terms of accuracy.However, the average lead time of the proposed EWSs in China's stock market is twice that of the U.S. stock market, and their distribution is more uniform, indicating that most EWSs occur almost one month before the actual events.In practical scenarios, investors can measure current and future risk levels by combining current return data with returns from the previous four days to establish the corresponding MRN and obtain the corresponding average mutual information.Then, they can re-apply the PELT-CROPS algorithm to the indicator series containing this new observation for detecting changepoints.The ellipse in Fig. 10 provides a simple illustration, where the triangle represents the new observation of average mutual information.If the observation is at the level of the blue or purple triangles, the previous point of the indicator cannot be identified as a potential EWS, and it is believed that extreme events are not likely to occur in the current or subsequent periods.If the observation is at the level of the red triangle, the average mutual information has undergone a sudden change, and the previous indicator will thus be identified as an EWS, indicating that extreme events may occur in the current and next few days.As shown in the density plot of Fig. 12, regardless of the market, the probability that EWSs will only lead extreme events by one day and the probability of extreme events occurring immediately at the current moment are both low.Therefore, the EWSs indicated by the changepoints of the average mutual information of MRN do have practical significance.

Comparison with benchmark methods
Due to the widely acknowledged empirical results of Guttal et al. on the early warning signals of financial crashes that may arise from rising volatility [27], we use their method as a benchmark to compare the strengths and weaknesses of our model from multiple perspectives, despite the significant differences between their method and ours in terms of quantitative techniques and methodology.Guttal et al. mainly identified potential EWS of financial crashes based on variance, mean power spectrum, and the autocorrelation function at lag-1, analyzing the price changes of major crashes in the stock market index four years before their occurrence in history [27].In order to ensure sufficient data for analysis before the identified crashes, the construction of the benchmark model is based on the daily closing prices of the Shanghai Composite Index from January 2, 2008, to October 30, 2020, six years longer than the sample used in previous empirical work.By using the 99.5th percentile of daily returns as the threshold to identify extreme events, we only concerned with whether the crashes that overlap with the negative events identified in the previous sample were correctly predicted, ensuring the comparability of the results.
Following the methodology mentioned above, we first identify the highest price points before the crashes and apply a Gaussian kernel smoothing function to remove the longterm trend of the four-year window (approximately 1000 days) before these highest price points, obtaining residuals for subsequent analysis.The bandwidth used in the detrending process is set to bw = 25.The length of the rolling window is set to lrw = 500 and the corresponding series of the lag-1 autocorrelation, variance, and low-frequency power spectrum are calculated based on the rolling windows.We then select a segment from the indicator series and estimate its Kendall's τ rank correlation coefficient with the sequence {1, 2, . . ., lkw} to determine whether the indicator exhibited an upward or downward trend within one year before the crash, where lkw refers to the length of the selected segment.And we define lkend as the distance from the endpoint of this segment to the highest price point before the crash.A positive (negative) Kendall's τ indicates an upward (downward) trend of the indicator.As this process involves four parameters, detailed sensitivity analysis is required to ensure the robustness of the conclusions.In the sensitivity analysis, the selection range of lrw is 375 to 625 with a step size of 10 (26 values), bw ranges from 2.5 to 100 with a step size of 2.5 (40 values), lkw ranges from 175 to 325 days with a step size of 5 days (31 values), and lkend ranges from 0 to 200 days with a step size of 5 (41 values).Therefore, for each indicator, a sample distribution of Kendall's τ can be obtained, which can indicate whether the selection of parameters directly affects the effectiveness of the trend of the indicator.
In addition to sensitivity analysis, we are also concerned with whether the estimated Kendall's τ before the crash is significant compared to a more distant past.To do this, we The first row presents the price trend of SSE for the 4 years (1000 days) prior to the crash and the corresponding detrended residuals.Autocorrelation at lag 1 does not show any clear trends, suggesting no EWS for any of these crashes in SSE.However, variance and average power spectrum show an increasing trend.The kendall-τ histograms for 2016 crash and 2020 crash indicate that this trend is strong and robust calculate all indicators and their Kendall's τ with the same parameter values of lrw, bw, lkw and lkend for the 1000-day historical window prior to the crash.The p-value determining the significance of Kendall's τ is defined as the proportion of values of Kendall's τ in this sample that are greater than or equal to the Kendall's τ of the data within one year before the crash.If this p-value is less than 0.1, it indicates that the trend of the indicator before the crash is significant at the 10% confidence level,and has an EWS effect.Otherwise, it cannot be considered as an effective EWS indicator.
Figure 13 shows the revealed trends of three indicators before the 2015 crash in China's stock market, the market meltdown in January 2016, and the crash caused by the COVID-19 pandemic in 2020.The histogram displays the distribution of the Kendall's τ obtained under sensitivity analysis.If the histogram shows an obvious peak close to 1, it indicates that the corresponding indicator's trend is robust to changes in parameters and shows a strong upward trend.It can be seen that the lag-1 autocorrelation does not show any obvious regular trend before the crashes, while the variance and mean power spectrum show a significant increase before the crashes.However, the histogram in the second column shows that this result is largely affected by the parameters in predicting the 2015 crash.The histograms in the fourth and sixth columns show a peak close to 1, indicating that the Kendall's τ of the indicators passes the sensitivity test in predicting the crashes in 2016 and 2020.Further, the p-value needs to be used to determine whether this upward trend has statistical significance, in order to determine whether the trends of variance and mean power spectrum can effectively predict these two crashes.
Table 3 lists the relevant results of the lag-1 autocorrelation, variance, and mean power spectrum for the prediction of crashes, i.e., negative extreme events.Since lkw is set to 0, it means that the lead time of these EWSs before a certain crash is the time distance between the highest price point before this crash and the exact moment of the crash.Table 2 shows that the autocorrelation at lag one cannot be regarded as an effective EWS, which is consistent with the conclusion of [27].The increasing trend of variance and mean power spectrum can partially predict crashes, with the mean power spectrum exhibiting a higher rate of accurate prediction, but still lower than that of the recurrence-based method proposed in this paper.There may be two possible reasons: first, as mentioned in the introduction section, these indicators are all based on univariate time series, and whether they can capture the complexity of the financial system remains to be considered; second, in this type of benchmark model, there is a de-trending process for time series, which may remove the characteristics such as long-term dependence of the time series.Furthermore, the selection of parameters, such as bw, during the data processing stage, greatly impacts the final results.The recurrence-based method better retains the weak complexity of the original series and considers the relationships between multidimensional time series, which can better restore the dynamic characteristics of the system.However, from the perspective of model construction, the benchmark has lower data requirements and simpler operations, and may be a more convenient tool for macroscopic observation of systemic risk.

Discussion and conclusion
The objective of this study is to investigate the potential application of multiplex recurrence-based analytical methods in monitoring early warning signals (EWSs) of extreme volatility, particularly financial crises occurring in financial markets.A simple simulation experiment demonstrates that the average mutual information and average edge overlap of the MRN can clearly distinguish the different states of a coupled system containing varying degrees of noise.Empirical results indicate that the peaks of average mutual information and average edge overlap, are effective in distinguishing different phases of the system, while their changepoints can be utilized as EWSs to forecast extreme financial volatility.The main contribution of this paper is to provide a general framework for monitoring EWSs before phase transitions in financial markets under strong complexity assumptions, which includes a quantitative method for detecting the changepoints.This framework retains the stylized facts of time series data, such as non-stationarity and long memory, and does not require dimensionality reduction, preserving the maximum complexity of the data.The EWSs detected in this study could capture the phase transition of the financial market more accurately than existing mainstream EWS indicators, providing new perspectives and tools for financial risk management.The empirical results reveal two interesting findings.Firstly, changepoints with an upward trend in the average mutual information of MRN can serve as potential EWSs for financial crises.Some readers may question how financial crises can be forewarned since they are usually triggered by extreme external events, which occur instantaneously.This can be explained in two ways.Firstly, the average mutual information of MRN essentially depicts the global similarity among the constituent stocks within the financial system.When this similarity abruptly increases, it indicates that investors' expectations about the future of the market are suddenly highly consistent, implying that the system itself is in a critical state, and the market can easily collapse if a random disturbance, such as a negative external event, is encountered.In other words, if the system is not in such a critical state, i.e., if the expectations of different traders are somewhat different, even if the same disturbance occurs, it may not lead to a collapse.Secondly, Peters, the author of the fractal market hypothesis, argues that trader heterogeneity, limited rationality, and information asymmetry lead to a certain response time to important information or events when traders trade [70].Considering the limitations of stock market trading hours, the daily upward and downward price limits, and the trading aggregation mechanism, the stock market has a response process to the occurrence of major events.Thus, there is a process from the release of public information to the emergence of extreme losses in the market, and the peak of homogeneity within the system may still occur before the final collapse, indicating that early warning is still significant.
The empirical results also reveal that the accuracy of EWSs in China's stock market is superior to that of the U.S. stock market.A possible explanation for this finding is the difference in market maturity between the two.The U.S. market is considered a more mature and efficient market, with relatively weak cyclicality and long memory between stock returns.In contrast, China's stock market is an emerging market that is relatively more susceptible to government macro manipulation, and hence, the cyclical pattern of the latter is more pronounced.Under the same set of recurrence rates, recurrence-based MRNs more accurately capture the properties of China's stock market, and hence, their indicators provide a more accurate description of the system dynamics' evolution.This suggests that the EWSs proposed in this study may be more suitable for identifying potential financial crises in emerging markets.

Figure 1
Figure 1 Illustration of the process for constructing multiplex recurrence network based on multidimensional time series.Subgraph (a) displays the original time series from three dimensions, marked as A, B, and C. The recurrence networks from the time series with a threshold of ε, yielding a recurrence rate of 0.05, are shown in subgraph (b).The multiplex recurrence network with edges weighted by inter-layer mutual information is displayed in subgraph (c)

Figure 2
Figure 2 Identification results of the indicators of MRNs for the CML systems with varying degree of noise.Different colored blocks correspond to the different states of the system determined by the coupling parameters

Figure 3
Figure 3 The Recurrence Networks in spiral layout based on the distance matrix of 56 return series of China' s stock markets in different time horizons.The phase transition can be indicated by the different colors of the vertices, which are displayed in time order.The vertices in red represent the "no recurrence" condition, the light blue vertices represent phase 1, and the dark blue vertices represent phase 2. Other conditions are marked by orange vertices

Figure 8
Figure 8 Market instability periods inferred from the topology of the MRN.The points of different colors indicate the different classifications of the MSTs of the corresponding MRNs during each unit time window, while the rectangles of different colors indicate the inferred different risk periods

φ
i=1 and {ω i } φ i=1 in China's stock market are 24 and 21, respectively, and the indicator series are divided into 25 and 22 segments.In the U.S. stock market, the optimal number of changepoints for {I i } φ i=1 and {ω i } φ i=1 are 35 and 10, respectively, and the indicator series are divided into 36 and 11 segments.The last point of each segment is regarded as the

Figure 9
Figure9 Diagnostic plots of the number of changepoints in the one-step rolling indicator series.When the curve becomes smooth after a certain point, the number of changepoints corresponding to that point is considered to be the relatively optimal choice

Figure 10
Figure 10EWSs and unstable periods of China' s stock market indicated by changepoints of MRN indicators.The red dots represent the changepoints of the indicators that are considered as EWSs, while the blue dots indicate the dates of actual financial extreme events.The color-coded rectangular blocks represent the different unstable periods predicted by different EWSs.The ellipse on the graph zooms in on the trend of an indicator at a certain time, serving as a schematic illustration of how the indicator can be used as an EWS in practical applications.The three colors of the triangle indicate the levels at which the average mutual information of the latest date may be located, and only the case corresponding to the red triangle indicates that the average mutual information of the previous day can be considered as a changepoint.Accordingly, the latest date and a period thereafter will be considered an unstable period with the possibility of extreme events

Figure 11
Figure 11 EWSs and unstable periods of China' s stock market indicated by changepoints of MRN indicators.The red dots represent the changepoints of the indicators that are considered as EWSs, while the blue dots indicate the dates of actual financial extreme events.The color-coded rectangular blocks represent the different unstable periods predicted by different EWSs

Figure 13
Figure13 Early warning signals of SSE for three major crashes of 2015, 2016 and 2020.Each of the two columns indicates the result corresponding to one of the crashes.The first row presents the price trend of SSE for the 4 years (1000 days) prior to the crash and the corresponding detrended residuals.Autocorrelation at lag 1 does not show any clear trends, suggesting no EWS for any of these crashes in SSE.However, variance and average power spectrum show an increasing trend.The kendall-τ histograms for 2016 crash and 2020 crash indicate that this trend is strong and robust M-layer multiplex recurrence network is constructed from M recurrence networks.For an M-dimensional time series, M different recurrence networks can be created that have the same number of N nodes, each of which represents a different time point.
The signal-to-noise ratios are set at 2, 10, and 20, respectively, meaning that 50%, 10%, and 5% noise are added.MRNs are established for the CML systems with and without noise, yielding the indicator values of MRNs under different coupling parameters.Figure2presents the results of state identification of the coupled system with varying noise levels in one experiment, using the average mutual information and average edge overlap.It is observed from the figure that the changes in the indicator series can effectively distinguish the different states of the system, such as Fully Developed Turbulence (FDT, a phase with incoherent spatiotemporal chaos and high-dimensional attractors, where ζ ∈ [0, 0.15] and ζ ∈ [0.19, 0.285]), [46,65,66]attern selection (PPS, a sharp suppression of chaos conducive to randomly selected periodic attractors, ζ ∈ [0.15, 0.19], and different forms of spatio-temporal intermittency (STI, a chaotic phase with low-dimensional attractors, actually a pseudo-phase interpolation between FDT and PS, ζ ∈ [0.285, 0.4])[46,65,66].Subsequently, we employ the Kruskal-Wallis Rank Sum test to verify the mean values of the indicators within the

Table 1 P
-values of Kruskal Wallis Rank Sum Test based on simulated coupled systems.The first column is the number of the experiment.Columns 2-5 correspond to the identification results of the average mutual information for systems with varying degrees of noise.Columns 6-9 correspond to the identification results of the average edge overlap for systems with varying degrees of noise windows of different states determined by the coupling parameter, to demonstrate that there is a significant difference in the means of the indicators during different states, thereby statistically substantiating the role of the indicators in identifying the state transition of systems with noise.We repeated the above experiment 10 times, and each test confirms the significant role of the indicators in identification, proving that this result is insensitive to the initial values in the CML system.Table1lists the p-values from the tests based on simulated systems with different noise, all of which are far less than 0.05.Thus, this simulation experiment demonstrates that the indicators of the multiplex recurrence networks are still applicable to complex systems with noise, laying a theoretical foundation for their application to financial time series.This study furnishes empirical substantiation derived from the Chinese and American equity markets, examining the applicability of the suggested methodology for detecting Early Warning Signals (EWS) within financial systems.The Shanghai Stock Exchange (SSE) Composite Index, chosen for its comprehensive representation of diverse industries and company sizes, serves as the empirical subject for China's market.This index's trajectory is perceived as the market's prevailing weathervane, signifying investor sentiment and market volatility.The Standard & Poor's 500 Index is employed for the United States market, given its significance as a gauge of economic well-being, with its fluctuations widely acknowledged as a measure of the overall American equity market.This study considers the returns of individual stocks in the index as variables of different dimensions of the market.When selecting stocks, it is essential to ensure that they are all constituents of the corresponding index within a predetermined historical time window and have data of the same length.The top constituent stocks are selected based on their market capitalization ranking to ensure a high degree of representativeness, while ensuring data integrity.Adhering to these criteria, 56 equities with relatively exhaustive data are designated to exemplify China's market across 56 dimensions, with their historical closing price data spanning January 3, 2014, to October 30, 2020.Conversely, 44 equities represent the U.S. market across 44 dimensions, with observed closing price values ranging from January 4, 2016, to December 30, 2022.The Appendix (see Additional file 1) contains Tables time

Table 2
The performance of the EWS indicated by the changepoints of average mutual information.The first column shows different statistical measures for the prediction results based on the changepoints of average mutual information, while the second and third columns show the corresponding results for the China's stock market and the U.S. stock market, respectively Figure 12 Density plots of the lead days of EWSs in two stock markets

Table 3
The performance of the EWS indicated by trends of indicators.The first column shows different statistical measures on the prediction results of China's financial crashes based on the benchmark indicators, and the second, third, and fourth columns show the corresponding results for the three benchmarks, respectively