Chu-Stinchcombe-White Test

The Chu-Stinchcombe-White Test (Chu, Stinchcombe and White, 1996) monitors a series for a structural change as new observations arrive. In the form López de Prado (2018) uses on prices, it asks whether the log price has risen by more since an earlier date than a random walk with the volatility up to now allows. It is one-sided, a test for a rise such as a breakout or a bubble, and as every date only uses the returns up to it, it can be run date by date without look-ahead.

The formula for the Chu-Stinchcombe-White Test starts from the log price \(y_{t}\), the cumulative sum of the log returns up to date t, with \(r_{i}\) the returns:

\[y_{t} = \sum_{i=1}^{t} \ln\left(1 + r_{i}\right)\]

It compares the rise of the log price since each earlier date n with the rise a random walk would show over the t - n periods in between, with hat(sigma_t)^2 the mean of the squared changes of y up to t:

\[S_{n,t} = \frac{y_{t} - y_{n}}{\hat{\sigma}_{t} \cdot \sqrt{t - n}}\]

The statistic at date t is the largest over the earlier dates n:

\[\text{CUSUM}_{\text{CSW}} = \max\left(S_{n,t}\right)\]

It is compared with the 5% critical value of Homm and Breitung (2012), which grows slowly with the distance t - n from the earlier date n that gives the maximum:

\[\text{Critical Value}_{\text{CSW}} = \sqrt{4.6 + \ln\left(t - n\right)}\]

A statistic above the critical value rejects stability: the log price has risen faster than a random walk allows. The test has no p-value. The 5% holds for each date on its own, so over many dates some cross the critical value by chance.

A CUSUM test asks whether a series stayed stable over time: the null hypothesis is that its mean (or its variance) did not change over the sample, the alternative that it changed at some date that is not known in advance. A test at a given date, such as the Chow test, needs that date; a CUSUM test cumulates the deviations from the stable model instead, and a break makes the cumulative sum drift away from where it would stay without one. A break in the mean return, from a change of regime, a merger or a new policy, makes any model fitted over the whole sample describe neither part well.

Also known as: CSW CUSUM, CSW test, bubble test.

In the Finance Toolkit this is get_cusum_test with method="chu_stinchcombe_white", the same function as CUSUM Test.

Example · BA, AIR.PA · 2021 to 2025

Install the Finance Toolkit with pip install financetoolkit -U, then call get_cusum_test:

from financetoolkit import Toolkit

toolkit = Toolkit(
    ["BA", "AIR.PA"],
    api_key="FINANCIAL_MODELING_PREP_KEY",
    start_date="2021-01-01",
    end_date="2025-12-31",
)

# The critical values are the asymptotic Brownian Bridge boundaries, so they
# are the same constants for every asset.
toolkit.econometrics.get_cusum_test(method="chu_stinchcombe_white")

Which returns:

Using Your Own Data

get_cusum_test runs on any data, not only prices: ratios, economic indicators, yield curves or your own dataset. Pass a DataFrame, a Series or a dictionary of them to Econometrics as data, with the dates in the rows or the columns, and set changes to how its changes are calculated: "percentage", "log", "difference" for rates and ratios, or None when the data are changes already. For example, for the monthly unemployment rates of the United States and Germany:

from financetoolkit import Economics, Econometrics

economics = Economics(start_date="2000-01-01")

unemployment = economics.get_unemployment_rate(
    countries=["United States", "Germany"], period="monthly"
)

econometrics = Econometrics(data=unemployment, changes="difference")

econometrics.get_cusum_test()

References

  • Paper Chu, C.-S.J., Stinchcombe, M. and White, H. (1996). “Monitoring Structural Change.” Econometrica, 64(5), 1045-1065.
  • Paper Homm, U. and Breitung, J. (2012). “Testing for Speculative Bubbles in Stock Markets: A Comparison of Alternative Methods.” Journal of Financial Econometrics, 10(1), 198-231.
  • Paper López de Prado, M. (2018). “Advances in Financial Machine Learning.” Wiley, section 17.3 (17.3.2 for the Chu-Stinchcombe-White test).
Share