Abstract
Online financial markets can be represented as complex systems where trading dynamics can be captured and characterized at different resolutions and time scales. In this work, we develop a methodology based on nonnegative tensor factorization (NTF) aimed at extracting and revealing the multitimescale trading dynamics governing online financial systems. We demonstrate the advantage of our strategy first using synthetic data, and then on realworld data capturing all interbank transactions (over a million) occurred in an Italian online financial market (eMID) between 2001 and 2015. Our results demonstrate how NTF can uncover hidden activity patterns that characterize groups of banks exhibiting different trading strategies (normal vs. early vs. flash trading, etc.). We further illustrate how our methodology can reveal “crisis modalities” in trading triggered by endogenous and exogenous system shocks: as an example, we reveal and characterize trading anomalies in the midst of the 2008 financial crisis.
Introduction
Social activity of individuals follows certain rhythms at different time scales. Many of the individual activities, such as sending emails and making phone calls, are likely to be done in particular time intervals within a day (i.e., diurnal or circadian cycles), and the total daily activity could heavily depend on the day of the week (i.e., weekly cycles)^{1,2,3,4,5,6}. In general, these social activity rhythms emerging at different time scales may be correlated with each other; for instance, it has been shown that facetoface contacts between classmates in a primary school follow a common diurnal cycle driven by the daily class schedule^{7,8}, yet at the same time they would also share activity rhythms at longer scales such as weekly and monthly, reflecting the annual school schedule.
As social communications between humans form temporal social networks, financial transactions between banks also shape timevarying networks^{9,10,11,12,13}. In the interbank market, for instance, overnight bilateral lending and borrowing between banks organize temporal networks whose structure changes on a daily basis, because the overnight financial contracts last for only one day^{11,12}. Thus, financial markets, similarly to social networks, can be interpreted as complex systems where each agent’s activity should be captured and characterized at appropriate time scales^{11,12}. In fact, many commonalities have recently been found between social communication patterns of humans and financial interaction patters of banks at particular temporal resolutions^{12,14,15}.
In recent years, nonnegative tensor factorization (NTF) has been frequently used to extract temporal activity patterns in various social contexts, such as facetoface contacts^{8,16}, Twitter posts^{17} and players’ matches in online games^{18}. Among these studies, Gauvin et al^{8}. showed that NTF is highly effective in detecting diurnal rhythms of students’ activity in a primary school^{7,19}. Characterizing diurnal rhythms lead the authors to uncover the multitimescale community structure formed by classmates: students’ temporal activity cycles, rather than the aggregated history of contacts, allows to reveal meaningful patterns that explain the complexity of children contact networks and communities.
Given the similarity between social and financial temporal dynamics, justified by underlying human factors, and the fact that multiple activity cycles are present at different frequencies in human social activities, our question is whether similar rhythms exist also in financial systems. In this work, we uncover hidden multitimescale patterns of banks’ activities in the Italian online interbank market, eMID^{20}. In previous studies, it has been recognized that there exist activity patterns in banks’ financial transactions at a particular time scale, such as interday^{12} and intraday scales^{21,22,23}. However, it is still unknown whether these patterns coexisting at different time scales are dependent on each other, in which case banks exhibiting a given interday activity pattern are likely to follow a particular intraday pattern.
We employ NTF as a tool to detect multitimescale patterns, in which banks’ activities are captured by a tensor having three dimensions: the list of banks, time of the day, and date. We will show that the PARAFAC decomposition of the 3way tensor^{24,25} indicates that banks’ trading activities can be classified into several patterns over the data period of 2001–2015. In particular, the NTF allows us to identify an anomalous pattern around the Lehman Brothers’ collapse in September 2008. Our multitimescale NTF approach reveals not only how banks facing the financial crisis changed their diurnal trading rhythms, but also on what dates such anomalies emerged.
Over the last couple of years, many proposals for measuring and controlling systemic risk have been presented, yet most of them focus on the static nature of financial networks^{26,27,28}. However, as we show in this study of the Italian eMID interbank market, various patterns and anomalies systematically emerge at different time scales, which should be taken into account in the design of financial regulations. Importantly, even in a situation in which bank activity has certain patterns at intra and interday scales, it remains of paramount importance to understand whether the intraday patterns are independent of the interday patterns (i.e., monotimescale patterns) or they are correlated with each other (i.e., multitimescale patterns). Our framework to extract multitimescale patterns advances the understanding of when and how banks react to systemic shocks, and in the future it could contribute to controlling the spread of financial systemic risk^{9,10,29,30,31}.
Data
We use the timestamped data on bilateral interbank transactions occurred between January 2001 and December 2015 in the Italian online interbank market (eMID). eMID is an online platform for financial institutions provided by the Italian company eMID SIM S.p.A. based in Milan, Italy (henceforth, we call financial institutions as “banks” for brevity). Banks in need of lending or borrowing funds may find a counterpart by posting an order on the online platform, which makes eMID a marketplace in which lenders and borrowers are matched. Each transaction record in this data represents when a loan contract agreement has been reached between two banks and how much funds have been lent (in million Euros). In addition, the data contains information about the type of each loan agreement, i.e., a lenderproposed transaction or a borrowerproposed transaction. We define a lenderproposed (resp., borrowerproposed) transaction to be a transaction proposed by a bank that lends to (resp., borrows from) its counterpart.
As in the other interbank markets, the vast majority of transactions (>86%) in the eMID market are overnight lending and borrowing (i.e., a loan contract lasts just for one day), while there are other types of transactions having longer maturity lengths such as two weeks, three month, etc. To eliminate the influence of differences in maturity length, we focus on overnight transactions of unsecured Euro deposits labeled as “ON” (i.e., overnight) or “ONL” (i.e., overnight large, namely overnight transactions greater than 100 million Euros). Table 1 summarizes the basic statistics of this dataset.
There are 3,839 business days over the data period between Jan 2, 2001 and Dec 31, 2015, on each of which transactions are made between 8:00 and 18:00. There are 289 banks that conducted at least one transaction over this period: 194 of them are Italian banks while the rest are foreign banks. Regardless of the nationality of banks, we examine the transactions conducted between 8:00–18:00 in Italian standard time. We do not consider a time difference between countries where the headquarters of the banks are located. The total number of transactions (ON and ONL) that we use in the analysis amounts to 1,148,699. It should be noted that the 289 banks are not always active over the data period (cf., Fig. 1a). In fact, the daily average of the number of participating banks is around 95, and the average number of daily transactions is approximately 300 (cf., Fig. 1b). Although the timeseries behaviors of the numbers of active banks and transactions are nonstationary, there is a stable scaling relationship between them (cf., Fig. 1c)^{12}. The dataset is commercially available from eMID SIM S.p.A (http://www.emid.it/).
Method
As noted in the previous section, banks are not always active in the interbank market. At the daily scale, some banks have transactions only on a certain fraction of business days while having no transactions on the other days^{12,21}. If we look at intraday time scales, on the other hand, the frequency of a bank having at least one transaction is not uniformly distributed over the time intervals^{21,22}. These heterogeneities in temporal bank activity are illustrated in Fig. S1.
Since the maturity of loan contracts is overnight, it is important to identify what are the days in which banks are more likely to be active. Conversely, since the participation of banks in the trading activity can change over the course of a day, it is also crucial to understand intraday activity changes. Due to the multiscale nature of bank trading activity, directly studying the volume of transactions of each bank over time would not allow us to detect inter and intraday dynamics. Thus, we need to disentangle each bank’s activity across the two dimensions (i.e., time scales): interday and intraday. To this aim, we represent our data in a threedimensional array (i.e., tensor), whose entries represent the amount of trades each bank performs at a given time of a given day. Given this multidimensional representation, our main goal is to extract some meaningful correlated multitimescale activity patterns related to groups of banks sharing a similar amount of transactions at the same time (respectively, intraday and interday). This can be achieved by means of nonnegative tensor factorization (NTF), as described in the following.
Nonnegative tensor factorization (NTF) at different time scales
Let us consider a threedimensional tensor \({\chi }\in {{\boldsymbol{{\mathbb{R}}}}}^{I\times J\times K}\), where I = N is the number of banks, J = T is the number of time intervals of bank activity in a day (here between 8:00 and 18:00), and K = D is the number of days. The entry \({x}_{ijk}\in {{\mathbb{Z}}}_{+}\) of the tensor \({\chi }\) denotes the total amounts of trades (in million Euros) conducted by the ith bank during jth time interval of the kth day. To extract the intra and interday trading patterns characterizing banks with similar amount of transactions over time, we rely on the NTF, which decomposes the tensor \({\chi }\) into the sum of several rankone tensors, namely components (cf., Fig. 2).
Here, we implement the NTF by applying the wellestablished method called PARAFAC (parallel factor analysis) or CANDECOMP (canonical decomposition) with nonnegativity constraints^{24,25,32}. The decomposition can be written as
where \(R\in {\mathbb{N}}\) denotes the number of components (i.e., the rank of the tensor), and the operator ° represents outer product. Eq. (1) is the socalled canonical polyadic decomposition (CP) of a tensor \({\chi }\), where \({{\bf{a}}}_{r}\in {{\mathbb{R}}}_{+}^{N}\), \({{\bf{b}}}_{r}\in {{\mathbb{R}}}_{+}^{T}\) and \({{\bf{c}}}_{r}\in {{\mathbb{R}}}_{+}^{D}\) represent rth component factors that respectively encode the membership of a bank to the component, the intervals in a day and the days in which the component is active (i.e. b_{r} and c_{r} are the intra and interday activity patterns of the groups of banks in a_{r}).
Let \({\bf{A}}\in {{\mathbb{R}}}_{+}^{N\times R}\), \({\bf{B}}\in {{\mathbb{R}}}_{+}^{T\times R}\) and \({\bf{C}}\in {{\mathbb{R}}}_{+}^{D\times R}\) denote the factor matrices, whose rth columns are the vectors a_{r}, b_{r} and c_{r}, respectively. The factor matrices A, B and C are calculated by solving the following minimization problem with nonnegativity constraints:
where \([\kern2pt[ {\bf{A}},{\bf{B}},{\bf{C}}]\kern2pt] \) represents the Kruscal form of the tensor decomposition (i.e., the RHS of Eq. (1)), and \(\parallel \cdot {\parallel }_{{\rm{F}}}\) denotes the Frobenius norm.
This minimization problem can be rewritten to perform the minimization with respect to one factor matrix at a time. Let X_{(n)} denote a matrix created by the moden matricization (or flattening) of tensor \({\chi }\), where each row of X_{(n)} consists of a vector corresponding to a given index of moden. That is, X_{(1)}, X_{(2)} and X_{(3)} are N × TD, T × ND and D × NT matrices, respectively. They can be expressed in terms of factor matrices as follows:
where \(\odot \) denotes the Khatri–Rao product, which is the “matching columnwise” Kronecker product defined as \({\bf{A}}\odot {\bf{B}}=[{{\bf{a}}}_{1}\otimes {{\bf{b}}}_{1},\ldots ,{{\bf{a}}}_{R}\otimes {{\bf{b}}}_{R}]\). The minimization problem for PARAFAC decomposition Eq. (3) can be now reformulated as
The minimizers of A, B and C of this problem are computed using the nonnegative alternate least squares method (ANLS) combined with the Block Principal Pivoting method (BPP) developed by^{33}. Our implementation is based on the Tensor Toolbox^{34,35} and the MATLAB codes available from^{36}.
Rank size
To determine the number of components R (i.e., rank size) used in the NTF model, we rely on the Core Consistency Diagnostic^{24}. Given the tensor element x_{ijk}, we can rewrite Eq. (2) as
where λ_{nmp} denotes the (n, m, p) element of the superdiagonal binary tensor \( {\mathcal L} \) (i.e., λ_{nmp} = δ_{nm}δ_{mp}δ_{np}). Now let g_{ijk} denote the (i, j, k) element of the core tensor \({\mathscr{G}}\), which is obtained by fitting the data to the Tucker3 model^{24}. In the Tucker3 model, the minimization problem reads
where X is a N × TD matrix converted from tensor \({\chi }\), and G is also a matricized version (R_{n} × R_{m}R_{p}) of the core tensor \({\mathscr{G}}\). With the Tucker3 decomposition, the tensor is written as
From the lemma of Bro and Kiers^{24}, the core tensor \({\mathscr{G}}\) will be identical to the superdiagonal tensor \( {\mathcal L} \) if the Tucker3 model is perfectly fitted and the factors have full column rank. If \({\mathscr{G}}\) is significantly different from the superdiagonal tensor \( {\mathcal L} \), by contrast, it means that there are nonnegligible interactions between factors and the PARAFAC model is not appropriate. Thus, we could assess whether the data should be fitted to the PARAFAC model or the Tucker3 model by measuring the distance between \({\mathscr{G}}\) and \( {\mathcal L} \).
We employ the Core Consistency (CC) value proposed by Bro and Kier^{24} as a measure of the distance between \({\mathscr{G}}\) and \( {\mathcal L} \):
where we imposed the constraint R_{n} = R_{m} = R_{p} = R in implementing the Tucker3 decomposition. CC takes 100 if the PARAFAC model perfectly fits the data and less than 100 (possibly a negative value) if the model does not fit perfectly. Note that a rise in R will reduce fitting errors while increasing the possibility of overfitting. In general, as R increases, there arises more interactions between components, which makes the core tensor \({\mathscr{G}}\) far from superdiagonal, resulting in a low value of CC. Therefore, it is reasonable to stop increasing R before the symptom of overfitting emerges. Our determination of R is given as
where CC(⋅) denotes the core consistency as a function of the number of components, and L_{cc} is a threshold parameter. In line with^{16}, we set L_{cc} = 85, and to minimize randomness created by a PARAFAC decomposition, we implement PARAFAC decomposition 20 times for a given rank size and use their mean as the value for CC(R′). Our implementation uses the MATLAB code available form^{37} which is based on the alternating nonnegativityconstrained least squares with block principal pivoting^{38}.
It should be noted that if one implements a lowdimensional clustering method, such as nonnegative matrix factorization, separately at different time scales, then in general one would obtain different numbers of monotimescale patterns at different scales. In that case, however, it would not be possible to know whether or not there exist multitimescale patterns such that banks exhibiting a common intraday pattern also show a common interday pattern.
Results
Synthetic temporal financial markets
To validate the accuracy of our multitimescale decomposition, we first implement NTF on a synthetic financial market whose properties are fully known ex ante. Suppose that there are three groups of banks, each of which having particular intra and interday trading patterns. First, we introduce intraday trading patterns by considering the “fitness” of banks. In the fitness model, the probability that banks i and j trade at time t is given by
where a_{i,t} ∈ [0, 1] denotes the fitness of bank i within the time interval [t − Δ, t]^{12,39}. Δ is the length of a time interval (in a day) expressed in minutes. Differences in the intraday trading patterns across groups are then represented by different values of fitness. Let us assume that the fitness evolves as illustrated in Fig. 3a. Banks belonging to group 1 are most active in the early morning (blue solid), and banks in group 2 exhibit the highest trading activity around noon (red solid), and banks in group 3 are most active at the end of the day (black dotted). More specifically, the fitness value of a bank belonging to group s at time interval t is given as
where f(t; μ_{s}, σ) is the p.d.f. of normal distribution with mean μ_{s} and standard deviation σ. We set (μ_{1}, μ_{2}, μ_{3}) = (0, T/2, T) and σ = T/4.
Second, the interday trading patterns are captured by variations in a bank’s participation probability, which is the probability that a bank participates in the market on a given day, apart from whether or not the bank is able to find a trading partner ex post. For day d = 1, …, D, the participation probability of bank i, denoted by q_{i,d}, is given as (Fig. 3b)
For simplicity, we assume that trade volumes are identical for all trades so that the (i, j, k) element of the 3dimensional tensor is equal to the total number of trades that bank i has during time interval j on day k. We will introduce a volume heterogeneity when analyzing the empirical data in the next section. We set N = 120, T = 20 (i.e., resolution Δ = 30 for hours between 8:00 and 18:00 in each day) and D = 1000.
Using the above synthetic tensor, we can now implement our multitimescale tensor factorization. The factorization of tensor \({\chi }\) allows us to measure the activity of each individual element: a bank, an intraday time interval, and a day. The activity of intraday time interval j of component r is given by b_{jr}, and analogously the activity of day k of component r is represented by c_{kr}. Figure 4 illustrates that PARAFAC decomposition well extracts the true multitimescale patterns. The coreconsistency value strongly suggests R = 3 since CC(4) takes a large negative value (Fig. 5).
Empirical data
Now we analyze empirical data. Given the accuracy of our method in the synthetic model, we expect the NTF method to extract latent multitimescale patterns in the realworld financial market, eMID. Here, we implement the N × T × D tensor factorization described in Method, where we set intraday time resolution (in minutes) Δ = {3, 5, 10, 15, 30, 45, 50}, and D is set at the total number of business days between January 2001 and December 2015 (i.e., D = 3, 839). The number of active banks N, which traded at least once during the period, is 289. The CoreConsistency will reveal the number of components R, if any, which is equivalent to the the variety of existent activity patterns.
CoreConsistency
The CC value for a given rank size is illustrated in Fig. 6a for Δ = 15. The CC value becomes lower than 85 for R ≥ 4, suggesting that R = 3 should be selected. In general, imposing different intraday resolutions may lead us to choose different values of R (Fig. 6b). There is a tendency that a higher resolution requires a larger number of components for the PARAFAC decomposition to be appropriate. In the following, we employ Δ = 15 and thereby R = 3 as the benchmark case, the rationale of which will be discussed in the next subsection.
Intraday and interday activity
Figure 7a shows intra and interday activities for Δ = 15, in which case there are three different patterns. The intraday activity of Component 1 is characterized by its bimodal pattern (Since the assignment of component index is originally arbitrary in the NTF implementation, we reassign index in the ascending order of cumulative intraday activity between 8:00 and 10:00). It has two peaks around 10:00 and 17:00. On the other hand, both Components 2 and 3 have a single distinct peak in the early morning, after which their activities are very low. However, the distribution of intraday activity of Component 3 is more skewed than that of Component 2, which makes Components 1 and 3 two polar cases and Component 2 in between them. We would call the trading patterns of Components 1, 2 and 3 as normal trading, early trading, and flash trading, respectively.
The activity patterns for different temporal resolutions are also presented in Fig. S2. For the case of a finer intraday resolution (e.g., Δ = 5, Fig. S2a), there are more than three components, and the activity of an additional component (i.e., Component 4) turns out to be very similar to the flashtrading pattern we saw in Fig. 7a. On the other hand, when the temporal resolution is low (e.g., Δ = 45, Fig. S2c), there are only two components and the flashtrading pattern is no longer detected. Given these observations, it is natural to set Δ = 15 as a benchmark case, where apparently independent intraday patterns can be captured. It should be noted that the following results are not sensitive to the temporal resolution level as long as R = 3 is to be selected (e.g., Δ = 30, Fig. S2b).
Figure 7b illustrates the interday activity of each component. For Components 1 and 2, the activity decreased radically during the global financial crisis of 2007–2009, which was initiated by a significant decline of the US house prices (the peak date is indicated by blue dotted). In contrast, the activity of Component 3 spiked around the collapse of Lehman Brothers in September 2008 (indicated by red dashed). Figure 7c shows how the share of a given component evolved over time.
These observations suggests that Component 3 captures the “crisis mode” of bank trading while Components 1 and 2 represent more normal trading patterns. The crisismode interpretation is reinforced by the intraday trading pattern of Component 3, in which banks trade only in the very early morning. In fact, we will show that, although we did not use information about the directionality of trades, this anomaly comes from the fact that banks in need of liquidity tried to obtain loans, rather than to extend credit, in the midst of the financial crisis.
Banks’ affiliation to components
Each element of vector a_{r} represents the extent to which a bank’s trading pattern is captured by Component r. Thus, we can extract a subgroup of banks whose trading patterns are characterized by Component r at least to some extent. Here, the set of banks belonging to component r is given by I_{r} = {i′} for which \({a}_{i^{\prime} r}\) is within the 90th percentile of \({\{{a}_{ir}\}}_{i\mathrm{=1}}^{N}\) (Fig. 8a). It should be noted that a bank may belong to multiple components if its trading pattern has multiple features (Fig. 8b).
The bank activity patterns emerging at the daily scale, captured by the row average of \({{\bf{a}}}_{r}{{\bf{c}}}_{r}^{{\rm{\top }}}\), exhibit explicit differences across components (Fig. 8c). While all types of banks have not been active since 2009, the normaltrading feature of banks belonging to Component 1 represents their behavior until 2008, and the trading pattern of banks belonging to Component 2 are dominated by the earlytrading pattern up to 2006. On the other hand, the banks belonging to Component 3 exhibit daily patterns similar to the other types of banks prior to 2008, but suddenly their activity level spiked around the collapse of Lehman Brothers.
Characterization of components
Aside from the intra and interday trading patters, it would be of interest to see whether we may characterize each component by inherent attributes of the belonging banks. In the eMID data set, a trading bank is classified into either of the following four types: aggressor lender, quoter lender, aggressor borrower and quoter borrower. In the eMID online platform, a bank posts a request for loans or a proposal for lending, and a loan contract is made if another bank accepts the posted request. A bank is called “aggressor lender” when the bank accepts a request for loan posted on the eMID platform, and the bank posted the request and borrowed fund is called “quoter borrower”. “quoter lender” and “aggressor borrower” can also be understood analogously. In addition, we can also ask to what extent the nationality of banks can explain the differences in trading patterns.
In fact, the majority of transactions in the eMID market were done between aggressor lenders and quoter borrowers, which is a common property to all the component types (Fig. 9a). However, more than half of the banks belonging to Component 3 are quoter borrowers and the share of aggressor lenders is significantly lower than that. As for the nationality, the share of Italian banks among all the banks belonging to Component 1 is significantly low while the corresponding fraction is significantly large for the banks in Component 2 (Fig. 9b) at 90% statistical significance, respectively. This suggests that foreign banks (i.e., banks from countries outside Italy) are likely to exhibit the normaltrading pattern, and Italian banks are more likely to employ the earlytrading pattern than foreign banks do.
These observations give us important implications about the multitimescale trading patterns in the financial market. First, flash trading, which represents the intraday trading pattern of Component 3, can be attributed mostly to quoter borrowers. Recall that flash trading was observed mostly in the period around the Lehman collapse in September 2008, but we do not know ex ante whether such a trading pattern was driven either by demand or supply. The fact that Component 3 is largely attributed to quoter borrowers suggests that the flashtrading pattern during the financial crisis was conducted by banks that attempted to obtain liquidity as early as possible by posting quotes for loans. This may be regarded as evidence that some banks in fact faced a serious liquidity shortage at the time of the Lehman collapse^{40,41}. Our multitimescale NTF approach reveals not only how banks reacted to the fear of liquidity shortage (i.e., intraday pattern), but also specific dates on which the fear was most evident (i.e., interday pattern).
Second, differences in the nationality of banks can lead to the variety of trading patterns. It turns out that foreign banks (Italian banks) are more likely to employ normal trading (early trading) than early trading (normal trading). On the other hand, the source of the crisis modality cannot be explained by the nationality of banks (Fig. 9b), suggesting that banks had similar chance of being in a crisis mode regardless of their nationalities.
Discussion
In this work, we presented an analytic framework based on nonnegative tensor factorization (NTF) to extract temporal activity patterns of financial systems. Despite previous studies on online financial markets recognized the existence of trading activity patterns at specific time scales (e.g., interday^{12}, or intraday^{21,22,23}), we demonstrated–to the best of our knowledge for the first time–that activity patterns coexist at different time scales and depend upon each other. Our methodology allowed us to uncover the hidden multitimescale patterns of trading activities in an online interbank market (eMID^{20}).
Within our framework, banks’ activities were represented by means of a tensor of three dimensions, namely the list of banks, time of the day, and date. Leveraging the power of NTF (based on the PARAFAC decomposition of the 3way tensor^{24,25}), we uncovered the multitimescale nature of financial trading dynamics in eMID, suggesting that banks’ trading patterns could be classified into subgroups exhibiting significantly different multitimescale patterns. Our framework also allowed us to attribute roles to banking institutions (aggressor lender/borrower, or quoter lender/borrower) based on their trading patterns, yielding interpretable analytic insights.
By modeling the multitimescale dynamics occurred over the period covered by our data (2001–2015), the proposed NTFbased framework allowed us to identify trading anomalies in the midst of the financial crisis. For example, around the time of Lehman Brothers’ collapse in September 2008, our approach showed how banks changed their trading rhythms, and on what dates such anomalies emerged.
Understanding trading patterns in financial systems is of fundamental importance for many reasons: first, a rigorous characterization of such systems’ trading dynamics could help central banks to effectively intervene in the interbank market. In turn, this would contribute to reducing systemic risk in the financial system as a whole. Financial linkages created by bilateral transactions between banks can lead to a global network of interconnected risk, in which a failure of one bank can immediately spread over the entire system^{9,29,30}. Extracting multitimescale patterns of financial markets allows for a better understanding of when and how banks react to systemic shocks.
Of course, the current approach has certain limitations. First, the tensor representation of interbank transactions does not capture information about the network aspect of the interbank market. While the current NTF takes bank ID, time and day as inputs, the interconnectivity between banks is still ignored. Given that many previous studies revealed that interbank networks contain rich information regarding systemic risk^{9,29,30}, including structural information in the framework could improve the results.
Second, while we focused on two different time resolutions, namely intra and interday, there could also be other timescales, such as weekly or monthly periodicity, that could contain meaningful information for characterizing the trading behavior of banks. However, the introduction of additional time scales would add more dimensions to the tensor, which would make it more challenging to find explicit patterns using the PARAFAC decomposition.
Third, the current analysis did not fully explore the role of multiscale activity patterns in propagating systemic risk. It would be interesting to examine to what extent each of the three activity patterns could promote or prevent financial contagion of bank defaults. To the best of our knowledge, the multitimescale aspect of the source of financial systemic risk has not been investigated so far. This appears as a promising future direction of this line of research.
Finally, while the current work focused on the Italian eMID market, this is just a small part of the entire financial system. There are many other interbank markets in different countries, and there are also other types of interbank transactions such as trading of government bonds and credit default swaps. An important question to ask would therefore be: are the multitimescale patterns found in our analysis ubiquitous or they are specific of markets that obey trading dynamics typical of the eMID market?
This work lays out the foundations for other researchers to study how patterns and anomalies emerge in financial systems at different temporal resolutions: in the future, such a framework could contribute to controlling the spread of financial systemic risk^{9,10,29,30,31}. It would be interesting to investigate whether our method could be used both in predictive and prescriptive ways to help determine what could happen under certain risk conditions, as well as to provide possible intervention strategies prior to shocks or cascading collapses in financial systems.
References
 1.
Malmgren, R. D., Stouffer, D. B., Motter, A. E. & Amaral, L. A. N. A Poissonian explanation for heavy tails in email communication. Proc. Natl. Acad. Sci. USA 105, 18153–18158 (2008).
 2.
Malmgren, R. D., Stouffer, D. B., Campanharo, A. S. L. O. & Amaral, L. A. N. On universality in human correspondence activity. Science 325, 1696–1700 (2009).
 3.
Jo, H. H., Pan, R. K. & Kaski, K. Emergence of bursts and communities in evolving weighted networks. PLOS ONE 6, e22687 (2011).
 4.
Jo, H. H., Karsai, M., Kertész, J. & Kaski, K. Circadian pattern and burstiness in mobile phone communication. New J. Phys. 14, 013055 (2012).
 5.
Aledavood, T., Lehmann, S. & Saramäki, J. Digital daily cycles of individuals. Front. Phys. 3, 73 (2015).
 6.
Aledavood, T. et al. Daily rhythms in mobile telephone communication. PLOS ONE 10, e0138098 (2015).
 7.
Stehlé, J. et al. Highresolution measurements of facetoface contact patterns in a primary school. PLOS ONE 6, e23176 (2011).
 8.
Gauvin, L., Panisson, A. & Cattuto, C. Detecting the community structure and activity patterns of temporal networks: a nonnegative tensor factorization approach. PLOS ONE 9, e86028 (2014).
 9.
May, R. M., Levin, S. A. & Sugihara, G. Complex systems: Ecology for bankers. Nature 451, 893–895 (2008).
 10.
Haldane, A. G. & May, R. M. Systemic risk in banking ecosystems. Nature 469, 351–355 (2011).
 11.
Barucca, P. & Lillo, F. Disentangling bipartite and coreperiphery structure in financial networks. Chaos Solitons Fractals 88, 244–253 (2016).
 12.
Kobayashi, T. & Takaguchi, T. Social dynamics of financial networks. EPJ Data Science 7(15), (2018).
 13.
Caccioli, F., Barucca, P. & Kobayashi, T. Network models of financial systemic risk: a review. J. Comput. Soc. Sci. 1, 81–114 (2018).
 14.
Starnini, M., Baronchelli, A. & PastorSatorras, R. Modeling human dynamics of facetoface interaction networks. Phys. Rev. Lett. 110, 168701 (2013).
 15.
Starnini, M., Baronchelli, A. & PastorSatorras, R. Model reproduces individual, group and collective dynamics of human contact networks. Soc. Netw. 47, 130–137 (2016).
 16.
Sapienza, A., Barrat, A., Cattuto, C. & Gauvin, L. Estimating the outcome of spreading processes on networks with incomplete information: a mesoscale approach. arXiv:1709.01806 (2017).
 17.
Panisson, A., Gauvin, L., Quaggiotto, M. & Cattuto, C. Mining concurrent topical activity in microblog streams. In Proceedings of the 4th workshop on ‘Making Sense of Microposts’, World Wide Web Conference 2014 (2014).
 18.
Sapienza, A., Bessi, A. & Ferrara, E. Nonnegative tensor factorization for human behavioral pattern mining in online games. Information 9, 66.
 19.
Cattuto, C. et al. Dynamics of persontoperson interactions from distributed RFID sensor networks. PLOS ONE 5, 1–9 (2010).
 20.
eMID SIM S.p.A website, http://www.emid.it/.
 21.
Iori, G., De Masi, G., Precup, O. V., Gabbi, G. & Caldarelli, G. A network analysis of the Italian overnight money market. J. Econ. Dyn. Control 32, 259–278 (2008).
 22.
Beaupain, R. & Durré, A. The interday and intraday patterns of the overnight market: Evidence from an electronic platform. ECB Working Paper 988 (2008).
 23.
Kobayashi, T. & Takaguchi, T. Identifying relationship lending in the interbank market: A network approach. arXiv:1708.08594 (2017).
 24.
Bro, R. & Kiers, H. A. A new efficient method for determining the number of components in PARAFAC models. J. Chemom. 17, 274–286 (2003).
 25.
Kolda, T. G. & Bader, B. W. Tensor decompositions and applications. SIAM Rev. 51, 455–500 (2009).
 26.
Beale, N. et al. Individual versus systemic risk and the regulator’s dilemm. a. Proc. Natl. Acad. Sci. USA 108, 12647–12652 (2011).
 27.
Gai, P., Haldane, A. & Kapadia, S. Complexity, concentration and contagion. J. Monet. Econ. 58, 453–470 (2011).
 28.
Kobayashi, T. & Hasui, K. Efficient immunization strategies to prevent financial contagion. Sci. Rep. 4, 3834 (2014).
 29.
Gai, P. & Kapadia, S. Contagion in financial networks. Proc. R. Soc. Lond. A Math. Phys. Sci. 466, 2401–2423 (2010).
 30.
Brummitt, C. D. & Kobayashi, T. Cascades in multiplex financial networks with debts of different seniority. Phys. Rev. E 91, 062813 (2015).
 31.
Battiston, S., Caldarelli, G., May, R. M., Roukny, T. & Stiglitz, J. E. The price of complexity in financial networks. Proc. Natl. Acad. Sci. USA 113, 10031–10036 (2016).
 32.
Lim, L.H. & Comon, P. Nonnegative approximations of nonnegative tensors. J. Chemom. 23, 432–441 (2009).
 33.
Kim, J. & Park, H. Fast nonnegative tensor factorization with an activesetlike method. In HighPerformance Scientific Computing, 311–326 (Springer, 2012).
 34.
Bader, B. W. et al. Matlab Tensor Toolbox version 2.6. http://www.sandia.gov/tgkolda/TensorToolbox/ (2015).
 35.
Bader, B. W. & Kolda, T. G. Efficient MATLAB computations with sparse and factored tensors. SIAM J. Sci. Comput. 30, 205–231 (2007).
 36.
Kim, J. Nonnegative Matrix and Tensor Factorizations, https://sites.google.com/site/jingukim/, accessed December 10, 2017.
 37.
Papalexakis, V. Fast and Efficient Core Consistency Diagnostic for Big Sparse Tensors, http://www.cs.ucr.edu/epapalex/code.html, accessed December 10, 2017.
 38.
Papalexakis, E. E. & Faloutsos, C. Fast efficient and scalable Core Consistency diagnostic for the PARAFAC decomposition for big sparse tensors. In Acoustics, Speech and Signal Processing (ICASSP ), 2015 IEEE International Conference on, 5441–5445 (IEEE, 2015).
 39.
De Masi, G., Iori, G. & Caldarelli, G. Fitness model for the Italian interbank money market. Phys. Rev. E 74, 066112 (2006).
 40.
Brunnermeier, M. K. Deciphering the liquidity and credit crunch 2007–2008. J. Econ. Perspect. 23, 77–100 (2009).
 41.
Allen, F. & Carletti, E. An overview of the crisis: Causes, consequences, and solutions. Intl. Rev. Finance 10, 1–26 (2010).
 42.
Federal Reserve Bank of St. Louis, FRED, S&P/CaseShiller U.S. National Home Price Index, https://fred.stlouisfed.org/series/CSUSHPINSA, accessed Feb 19, 2018.
Acknowledgements
TK acknowledges financial support from the Japan Society for the Promotion of Science Grants no. 15H05729 and 16K03551. EF is grateful to DARPA for support (grant #D16AP00115). This project does not necessarily reflect the position/policy of the Government; no official endorsement should be inferred. Approved for public release; unlimited distribution.
Author information
Affiliations
Contributions
T.K. and E.F. conceived the research and wrote the manuscript. T.K. performed the analysis. T.K., A.S. and E.F. discussed the results and reviewed the manuscript.
Corresponding author
Ethics declarations
Competing Interests
The authors declare no competing interests.
Additional information
Publisher's note: Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
Electronic supplementary material
Rights and permissions
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons license, and indicate if changes were made. The images or other third party material in this article are included in the article’s Creative Commons license, unless indicated otherwise in a credit line to the material. If material is not included in the article’s Creative Commons license and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this license, visit http://creativecommons.org/licenses/by/4.0/.
About this article
Cite this article
Kobayashi, T., Sapienza, A. & Ferrara, E. Extracting the multitimescale activity patterns of online financial markets. Sci Rep 8, 11184 (2018). https://doi.org/10.1038/s4159801829537w
Received:
Accepted:
Published:
Further reading

The structured backbone of temporal social ties
Nature Communications (2019)
Comments
By submitting a comment you agree to abide by our Terms and Community Guidelines. If you find something abusive or that does not comply with our terms or guidelines please flag it as inappropriate.