1 Introduction

The statistical process control (SPC) charts are widely used in industry for monitoring stability of certain sequential processes like manufacturing, health care systems etc. Traditional models under SPC assume that there are two causes of variability in the process measurements: one is “common cause” which is due to unavoidable randomness and another one is “special cause” which is usually due to mechanical defects or improper handling of machines, human errors etc. that can potentially be identified and removed. When common causes are the only source of variability then the process is said to be “in-control”. When a system is “in-control”, the process measurements can be considered as realizations of some random model, for example, independent and identically distributed (i.i.d.) observations from a cumulative distribution function (c.d.f.) \(F_1\). In case a special cause intervenes, the process measurements no longer appear as i.i.d. realizations of \(F_1\), and then the system is said to be “out-of-control”. Practitioners usually divide SPC into two phases. A set of process measurements are collected and analyzed in phase I. Adjustments and fine tuning of the system are made if any “unusual” patterns in the process measurements are found. When all such special causes are removed, we have a set of process measurements data under stable operating conditions and they are representative of the actual process performance. In phase II, the major goal of SPC control charts is to detect any change in the distribution of process measurements after an unknown time point.

A change in the process distribution can be of many types. For example, shift in (i) mean, (ii) variance, (iii) skewness, (iv) kurtosis, or (v) higher moments, or (vi) any arbitrary combination of (i)–(v). Furthermore, changes can either be isolated, i.e. the systems goes “out-of-control” and then returns to “in-control”, or persistent, i.e. once the system goes “out-of-control” it remains “out-of-control” or even goes further away from control until the special cause is removed. Among existing SPC charts, Shewhart-type (Shewhart 1931) charts are used to detect isolated changes, cumulative sum (CUSUM) type charts (e.g., Page 1954) are used to detect persistent changes. However, most SPC charts mainly consider shifts in mean and/or variance, because they are most common and often captures other departures. In real world problems, shifts in skewness and kurtosis can happen without much change in mean and/or variance. For example, the response distribution changes from \(N(0,1)\) to a standardized version (i.e., mean \(0\) and variance \(1\)) of Student’s t-distribution with \(5\) degrees of freedom. If we fail to detect those changes and let the process run, it can eventually become worse and a shift in mean or variance can creep in. Moreover, the special cause that initiated the change can cause more damage to the system, and it may become a financial challenge to fix it. If we can detect such change in kurtosis, we can avoid subsequent troubles. Therefore, it is desirable to develop an SPC chart that can detect changes in the process distribution. This paper focuses on univariate processes and aims to detect such changes when the “in-control” c.d.f. \(F_1\) is continuous but its parametric form is unavailable. It is also assumed that phase I data are available.

Many different versions of SPC control charts have been proposed in the literature including Shewhart type charts (Shewhart 1931), cumulative sum (CUSUM) type charts (e.g., Page 1954), exponentially weighted moving average (EWMA) type charts, charts based on change point detection (CPD) (e.g., Hawkins et al. (2003) and Zhou et al. (2009)) etc. Many control charts in the literature assume that “in-control” response distribution \(F_1\) has a parametric form (e.g., normal). However, the process observations may not follow a pre-specified parametric form in a real life problem. It has been demonstrated in the literature that the charts using pre-specified distribution in their design many not be reliable in such cases (e.g., Amin et al. (1995), Hackl and Ledolter (1992) and Lucas and Crosier (1982)). To address this, a number of distribution free or non-parametric methods have been proposed. For example, Albers and Kallenberg (2004, 2009), Albers et al. (2006), Amin et al. (1995), Amin and Searcy (1991), Amin and Widmaier (1999), Bakir (2004, 2006), Bakir and Reynolds (1979), Chakraborti et al. (2004, 2009), Chakraborti and Eryilmaz (2007), Hawkins and Deng (2010) and Liu et al. (2014), and so on. An overview on the existing research area on univariate distribution free SPC can be found in Chakraborti et al. (2001). Related discussions in the multivariate cases can be found in Qiu and Hawkins (2001, 2003) and Qiu (2008). Some SPC charts (e.g., Yeh et al. (2004) and Hawkins and Zamba (2005) consider joint monitoring of process mean and variance. Moustakides (1986) provides a method to detect distributional change when both “in-control” and “out-of-control” distributions are known. Ross and Adams (2012) provide two nonparametric control charts to detect any distributional change under the change point detection (CPD) framework when both “in-control” and “out-of-control” distributions are unknown. A thorough literature review on SPC charts can be found in Hawkins and Olwell (1998) and Qiu (2013) etc.

Most existing SPC charts mentioned above aim to detect changes in process mean and/or variance, but do not consider higher moments. Moreover, many of those methods require multiple observations at each time point. This paper proposes a nonparametric SPC chart for detecting change of univariate process distribution that neither assumes any parametric form of the “in-control” distribution nor requires multiple observations at each time point. The only mild underlying assumptions are: (i) the “in-control” distribution function \(F_1\) is continuous, (ii) the process measurements are independent of each other, and (iii) phase I data are available. The major steps of the proposed SPC chart are the following: First, we estimate \(F_1\) by the “in-control” (IC) phase I data. Next, we calculate corresponding quantiles of the phase II data with respect to estimated \(F_1\) (expression (1)). Under no distributional change, these quantiles should be uniformly distributed between \(0\) and \(1\). Using an appropriate amount of previous quantiles along with the present, we keep performing one-sample Kolmogorov–Smirnov (KS) tests to check that and calculate corresponding p values. We signal a distributional change once a p value is small. Some practical guidelines are also provided when to use or not to use the proposed chart. In addition to this, another major contribution of this paper is the idea of pruning parts of phase II data from distant past based on current p values (Sect. 2.1) that can potentially be useful in many popular charts when phase II data arrive rapidly.

The remainder of the paper is organized as follows. The proposed control chart is described in Sect. 2. Numerical studies to evaluate its performance in comparison with several existing control charts are presented in Sect. 3. Section 3 also provides some discussions about the proposed chart in various scenarios. One real data analysis by the proposed chart and its competitors is presented in Sect. 4. A few remarks in Sect. 5 conclude this paper.

2 The proposed control chart

As mentioned before, the proposed nonparametric SPC chart aims to detect distributional change when a parametric form of the “in-control” distribution \(F_1\) is unknown. The only assumptions made are: \(F_1\) is continuous, the observations at both phases I and II are independent of each other, and an “in-control” data-set has been collected at phase I analysis. Although it is still challenging to perform phase I analysis when \(F_1\) is unknown (Jones-Farmer et al. 2009), it is not the focus of this paper.

2.1 Description of the proposed control chart

The first step of the proposed SPC chart is to estimate \(F_1\). In this paper, we do this by the conventional empirical distribution function \(\widehat{F}_1\) based on i.i.d. phase I data denoted by \(X_1, X_2, \ldots , X_M\) where \(M\) is the total number of phase I observations. Let \(\mathbf {Y}(n) = (Y_1(n), Y_2(n), \ldots , Y_m(n))^T\) be \(m\) i.i.d. observations obtained at the time point \(n\) during phase II process monitoring. In the literature, they are often called batch data or sub-grouped data. When \(m=1\), it is called single-observation data. Once we get a batch of data \(\mathbf {Y}(n)\) during phase II monitoring, we estimate its corresponding quantiles, assuming no distributional change in phase II, by the following formula:

$$\begin{aligned} \widehat{Q}_i(n) = \widehat{F}_1(Y_i(n)) = \frac{1}{M} \left| \{j : X_j \le Y_i(n), 1\le j \le M\} \right| \,\text{ for } \,i=1,2, \ldots , m,\nonumber \\ \end{aligned}$$
(1)

where \(|.|\) is the cardinality of a set. When \(M\) is large and there is no distributional change, then we know that \(\widehat{Q}_i(n)\) approximately follows the Uniform distribution \(U[0,1]\). This result is due to Glivenko–Cantelli’s Theorem (Loève 1955) and probability integral transform (Casella and Berger 2002). The proposed control chart uses this result to signal any distributional change. As we keep collecting phase II batches of data at each time point, we keep performing one-sample Kolmogorov–Smirnov (KS) tests to check whether a pool of ‘recent’ estimated data quantiles (i.e., \(\widehat{Q}_i(n)\)) follow \(U[0,1]\) distribution. As soon as we find a significant evidence against it, we signal a distributional change.

The algorithm of the proposed control chart runs as follows. Once we receive the first batch of data \(\mathbf {Y}(1)=(Y_1(1), Y_2(1), \ldots , Y_m(1))^T\), we calculate the corresponding \(\widehat{Q}_i(1)\)’s by the formula provided in (1). Next, we define an effective set of data quantiles (ESDQ) at the first time point as \(\text{ ESDQ }(1) = \{\widehat{Q}_1(1), \widehat{Q}_2(1), \ldots , \widehat{Q}_m(1)\}\) and perform the one-sample KS test to check if the numbers in \(\text{ ESDQ }(1)\) are i.i.d. realizations from \(U[0,1]\) distribution. Obviously, when \(m=1\), we can not perform one-sample KS test. In that case, we define the p value \(p_1\) to be \(1.0\). In case the p value \(p_1\) is smaller than the control limit \(h_P\), we signal a distributional change. Otherwise, we collect the second batch of data \(\mathbf {Y}(2)=(Y_1(2), Y_2(2), \ldots , Y_m(2))^T\) and define \(\text{ ESDQ }(2)\) by including new quantiles in \(\text{ ESDQ }(1)\), i.e., \(\text{ ESDQ }(2) = \{ \text{ ESDQ }(1), \widehat{Q}_1(2), \widehat{Q}_2(2), \ldots , \widehat{Q}_m(2) \}\). Like before, we then perform the one-sample KS test to check if the numbers in \(\text{ ESDQ }(2)\) follow \(U[0,1]\) distribution. If \(p_2 < h_{P}\), we signal a distributional change, and if \(p_2\) is so large that \(p_2 > k_P \cdot h_{P}\), where \(k_P\) is a tuning parameter of the proposed control chart, we decide to check whether we need to prune some batches of quantiles from past. The major reason behind pruning is to increase the efficiency of the proposed control chart in detecting a distributional change. If we do not prune at all at any stage of the algorithm, then once the “in-control” phase II data-set becomes large, it will require a lot of “out-of-control” phase II data to detect a distributional change. Intuitively, the amount of pruning should depend on the value of \(p_2\) in comparison with \(k_P \cdot h_P\). If \(p_2\) is large, say, close to \(1.0\), then we may want to prune quite a large amount from the past. On the other hand, if \(p_2\) is not so large, then we should not prune much from the past. One simple approach is to prune \(100 \left( \frac{p_2 - k_P h_P}{1 - k_P h_P}\right) ^2 \%\) of the oldest batches. However, to make sure that we do not prune too much in a single step, we propose pruning the oldest \(\Bigl \lfloor 2. \min \left( 0.2, \left( \frac{p_2 - k_P h_{KS}}{1 - k_P h_{KS}}\right) ^2 \right) \Bigr \rfloor \) batches of quantiles from \(\text{ ESDQ }(2)\), where \(\Bigl \lfloor \psi \Bigr \rfloor \) is the largest integer smaller than or equal to \(\psi \). We keep on proceeding like this. On the receipt of the \(n\)-th batch of data \(\mathbf {Y}(n) = (Y_1(n), Y_2(n), \ldots , Y_m(n))^T\) where \(n>1\), if we can go that far, we define \(\text{ ESDQ }(n) = \{ \text{ ESDQ }(n-1), \widehat{Q}_1(n), \widehat{Q}_2(n), \ldots , \widehat{Q}_m(n) \}\). Similar to previous iterations, we perform the one-sample KS test to check if the quantiles in \(\text{ ESDQ }(n)\) follow \(U[0,1]\) distribution. In the case \(p_n < h_P\), we signal a distributional change, and if \(p_n > k_P \cdot h_P\), we re-define \(\text{ ESDQ }(n)\) by pruning the earliest \(b(n,p_n,k_P,h_P) = \Bigl \lfloor n. \min \left( 0.2, \left( \frac{p_n - k_P h_P}{1 - k_P h_P}\right) ^2 \right) \Bigr \rfloor \) number of batches of quantiles from \(\text{ ESDQ }(n)\). We keep on collecting future batches of data until we detect any distributional change. A summary of the proposed chart is provided below.

The algorithm of the proposed control chart

Initialization Part: (when \(n=1\))

  1. (1)

    Set the time point \(n=1\), collect the first batch of phase II data, and define \(\text{ ESDQ }(1) = \{\widehat{Q}_1(1), \widehat{Q}_2(1), \ldots , \widehat{Q}_m(1)\}\) using the formula in (1).

  2. (2)

    Find the p value \(p_1\) of the one-sample KS test to check whether the numbers in \(\text{ ESDQ }(1)\) are i.i.d. realizations from \(U[0,1]\) distribution. If \(m=1\), one-sample KS test can not be performed. In that case, define \(p_1 = 1.0\).

  3. (3)

    If \(p_1 < h_P\), signal a distributional change and stop the algorithm.

  4. (4)

    Increase \(n\) by \(1\).

Main Part: (when \(n > 1\))

  1. (1)

    Define \(\text{ ESDQ }(n) = \{\text{ ESDQ }(n-1), \widehat{Q}_1(n), \widehat{Q}_2(n), \ldots , \widehat{Q}_m(n) \}\).

  2. (2)

    Find the p value \(p_n\) of the one-sample KS test to check whether the numbers in \(\text{ ESDQ }(n)\) are i.i.d. realizations from \(U[0,1]\) distribution.

  3. (3)

    If \(p_n < h_P\), signal a distributional change and stop the algorithm.

  4. (4)

    If \(p_n > k_P \cdot h_P\), re-define \(\text{ ESDQ }(n)\) by pruning the earliest \(b(n,p_n,k_P,h_P)\) batches of quantiles from \(\text{ ESDQ }(n)\).

  5. (5)

    Increase \(n\) by \(1\).

  6. (6)

    Keep repeating the steps in ‘Main Part’ until a distributional change is signaled.

2.2 Determination of the control limit \(h_P\) based on specified average run length (\(ARL_0\)), and selection of the tuning parameter \(\kappa _P\)

The performance of the SPC charts are often measured by their run length (RL) distribution, i.e., the number of samples needed to signal a change in process distribution. When the process is “in-control”, the run lengths should typically be long, but when the process goes “out-of-control” then the run lengths should be short. In practice, the comparisons of the RL distributions are often performed by average run lengths (ARL). The “in-control” (IC) ARL is usually controlled at a given level \(ARL_0\). Then, an SPC chart performs better if its “out-of-control” (OC) ARL is shorter. Hawkins and Olwell (1998) provide related discussions.

The control limit \(h_P\) of the proposed SPC chart for a specified tuning parameter \(k_P\) and given \(ARL_0\) is searched as follows. We keep simulating phase II data quantiles, i.e. \(\widehat{Q}_j(i)\)’s of batch size \(m\) from \(U[0,1]\), because under no distributional change, \(\widehat{Q}_j(i) \sim U[0,1]\). The proposed control chart for the specified \(k_P\) and an arbitrarily chosen control limit keeps running until a distributional change is signaled. These steps are repeated many times (say, \(10{,}000\) times) and the average run length (ARL) is calculated. If this ARL value is substantially different from \(ARL_0\), we run the proposed chart with different choices of the control limit. We keep doing this until the average run length based on a large number of repetitions is reasonably close to \(ARL_0\). Unless otherwise specified, the control limits of the proposed chart is chosen by this data-driven approach in the numerical examples in this paper. Note that we do not need to simulate phase II data \(Y_i(n)\)’s to simulate \(\widehat{Q}_j(i)\)’s, because under no distributional change, \(\widehat{Q}_j(i) \sim U[0,1]\).

To select \(k_P\), we first find the control limits of the proposed chart for various values of \(k_P\). Then, we select the tuning parameter \(k_P\) that generates the smallest “out-of-control” ARL when a specified shift that we are interested in, e.g., a mean increase of \(0.6\) has taken place. An elaboration is provided in Sect. 3.2.

3 Numerical studies

In this section, some numerical examples are presented to evaluate the performance of the proposed control chart in comparison with a few existing popular ones. Specifically, we compare the performance of the control charts in terms of shift detection in mean, variance, skewness and kurtosis separately. We call the proposed chart as PROPOSED hereafter. The existing control charts considered here are briefly introduced in Sect. 3.1. Then, the related control charts are compared in various scenarios in Sect. 3.2. Some discussions about the proposed control chart in various scenarios are provided in Sect. 3.3.

3.1 Some representative existing control charts

The traditional CUSUM chart is a standard tool for monitoring the mean of univariate processes in practice. Its charting statistics of the two-sided version are defined by

$$\begin{aligned} u_{n,N}^{+}&= \max \left( 0, u_{n-1,N}^{+} + \overline{Y}(n) - k_N \right) \!, \\ u_{n,N}^{-}&= \min \left( 0, u_{n-1,N}^{-} + \overline{Y}(n) + k_N \right) \!, \end{aligned}$$

where \(n>1\), \(u_{0,N}^{+} = u_{0,N}^{+} = 0\), \(k_N\) is an allowance constant, \(\overline{Y}(n) = \frac{1}{m} \sum _{j=1}^{m} Y_j(n)\), and the subscript “N” denotes the fact that this method is based on the normal-distribution assumption. Then, a mean shift in \(\mathbf {Y}(n)\) is signaled if

$$\begin{aligned} u_{n,N}^{+} > h_{N} \, \text{ or } \, u_{n,N}^{-} < - h_{N} \end{aligned}$$
(2)

where the control limit \(h_N > 0\) is chosen to achieve a given IC ARL level. This chart is called N-CUSUM chart in this paper.

When the process distribution is not normal, Borror et al. (1999) showed that a properly designed EWMA (exponentially weighted moving average) chart is robust to departures from normality. More specifically, the EWMA charting statistics is defined by

$$\begin{aligned} v_n = \lambda \overline{Y}(n) + (1 - \lambda ) v_{n-1}, \end{aligned}$$

where \(v_0 = 0\), \(\lambda \in [0, 1]\) is a weighting parameter, and \(\overline{Y}(n) = \frac{1}{m} \sum _{j=1}^{m} Y_j(n)\). Then, a mean shift in \(\mathbf {Y}(n)\) is signaled if

$$\begin{aligned} |v_n| \ge h_R, \end{aligned}$$
(3)

where \(h_R > 0\) is a control limit chosen to achieve a pre-specified IC ARL level. This chart is called EWMA chart in this paper.

This paper also considers distribution-free control charts for monitoring the mean of an univariate process. The chart originally proposed by Chakraborti and Eryilmaz (2007) is a Shewhart-type chart, based on the statistic

$$\begin{aligned} \psi (n) = 2W_n^{+} - \frac{m(m+1)}{2}, \,\, n \ge 1, \end{aligned}$$

where \(W_n^{+}\) is the Wilcoxon signed-rank statistic of \(\mathbf {Y}(n)\), defined to be the sum of the ranks of \(\{|Y_j(n)- \theta _0|, j=1,2,\ldots ,m\}\) over all positive components of \(\{Y_j(n)- \theta _0, j=1,2,\ldots ,m\}\), and \(\theta _0\) is the IC median of the process distribution which can be estimated from phase I data. Since, we want to detect persistent shifts, rather than one-time shifts, a CUSUM chart based on \(\psi (n)\) can easily be constructed as follows. Let \(u_{0,S}^{+}=u_{0,S}^{-}=0\), and for \(n \ge 1\)

$$\begin{aligned} u_{n,S}^{+}&= \max \left( 0, u_{n-1,S}^{+} + (\psi (n) - \psi _0) - k_S \right) \!, \\ u_{n,S}^{-}&= \min \left( 0, u_{n-1,S}^{-} + (\psi (n) - \psi _0) + k_S \right) \!, \end{aligned}$$

where \(k_S\) is an allowance constant, and \(\psi _0\) is the IC mean of \(\psi (n)\) which can be estimated from IC phase I data. Then, this CUSUM chart signals a mean shift in \(\mathbf {Y}(n)\) if

$$\begin{aligned} u_{n,S}^{+} > h_{S} \, \text{ or } \, u_{n,S}^{-} < - h_{S}, \end{aligned}$$
(4)

where the control limit \(h_S\) is chosen to achieve a given IC ARL level. This chart is called S-CUSUM hereafter.

For monitoring location shift in the unknown process distribution, Hawkins and Deng (2010) proposed a change-point detection control chart based on Mann-Whitney two-sample statistic. This chart is based on the assumption that the observations are un-batched, i.e., the batch size is \(m=1\). Therefore, if the batch size \(m\) is larger than \(1\), we pretend that in each batch we get the observations in a random order. Suppose, the sequential observations after time \(n\) are \(V_1, V_2, \ldots , V_{t}\), where \(t=M+mn\), \(V_1, V_2, \ldots , V_M\) is a random sequence of the phase I data, \(V_{M+1}, V_{M+2}, \ldots , V_{M+m}\) is a random sequence of \(\mathbf {Y}(1)=(Y_1(1), Y_2(1), \ldots , Y_m(1))\), \(V_{M+m+1}, V_{M+m+2}, \ldots , V_{M+2m}\) is a random sequence of \(\mathbf {Y}(2)=(Y_1(2), Y_2(2), \ldots , Y_m(2))\), and so on. This chart is based on the following statistic:

$$\begin{aligned} T_{k,t} = \frac{U_{k,t}}{\sqrt{k(t-k)(t+1)/3}}, \end{aligned}$$

where \(U_{k,t} = 2 \sum _{i=1}^{k}R_i - k(t+1)\) is equivalent to Mann-Whitney statistic, \(k\) is the possible change point under consideration, \(R_i\) is the rank of \(V_i\) among currently available observations (i.e., \(V_1, V_2, \ldots , V_{t}\)). The test statistic for testing location shift in the IC distribution is defined by

$$\begin{aligned} T_{\mathrm{max},t} = \max _{1 \le k \le t-1} |T_{k,t}|. \end{aligned}$$

We conclude that there is a location shift before \(V_{t}\), if

$$\begin{aligned} T_{\mathrm{max},t} > h_{t}. \end{aligned}$$
(5)

In that case we detect a distributional shift at or before time \(n\). \(h_{t}\) is chosen to achieve a given IC ARL level. Please note that the change detection starts after \(V_M\) in the numerical studies in this paper. We refer to this chart by HD-MW hereafter. Implementations of HD-MW in this paper are performed by the R package ‘cpm’ developed by Ross (2013).

Next, we discuss some popular control charts for detecting shifts in variance. Hawkins (1981) proposed using the transformed observations

$$\begin{aligned} W_n = \frac{\sqrt{|Z_n|} - 0.822}{0.349} \end{aligned}$$

in the traditional CUSUM chart for detecting shifts in variance. It works because phase II single observation data \(Z_n\), and \(W_n\) approximately follow the same IC distribution, specially when the IC distribution is normal. In case of our batched data, \(\overline{Y}(n)\) is used in place of \(Z_n\). This chart is called VC-HK hereafter.

Another simple chart to detect shifts in variance uses \(S_n-1\) in place of \(\overline{Y}_n\) in the traditional CUSUM chart, where \(S_n\) is the sample standard deviation of the observations at the \(n\)-th time point. We call this chart SD-CUSUM hereafter.

Ross and Adams (2012) provide two distribution free charts for detecting distributional changes during phase II monitoring. They integrate Kolmogorov–Smirnov and Cramer–von-Mises tests into change-point model framework. As recommended in Ross and Adams (2012) the chart based on Cramer–von-Mises is considered in this paper. This control chart is also based on single observation data. Similar to HD-MW chart, we pretend that in each batch we get the observations in a random order. Suppose the sequential observations after time \(n\) are \(V_1, V_2, \ldots , V_{t}\), where \(t=M+mn\), \(V_1, V_2, \ldots , V_M\) is a random sequence of the phase I data, \(V_{M+1}, V_{M+2}, \ldots , V_{M+m}\) is a random sequence of \(\mathbf {Y}(1)=(Y_1(1), Y_2(1), \ldots , Y_m(1))\), \(V_{M+m+1}, V_{M+m+2}, \ldots , V_{M+2m}\) is a random sequence of \(\mathbf {Y}(2)=(Y_1(2), Y_2(2), \ldots , Y_m(2))\), and so on. This control chart is based on the following statistic:

$$\begin{aligned} W_{k,t} = \sum _{i=1}^{t} |\widehat{F}_{S_1}(V_i) - \widehat{F}_{S_2}(V_i)|, \end{aligned}$$

where

$$\begin{aligned} \widehat{F}_{S_1}(v)&= \frac{1}{k} \sum _{i=1}^{k} I(V_i \le v), \\ \widehat{F}_{S_2}(v)&= \frac{1}{t-k} \sum _{i=k+1}^{t} I(V_i \le v), \end{aligned}$$

and \(k\) is the possible change point under consideration. Under the change-point framework this leads to the following maximized test statistic:

$$\begin{aligned} W_{t} = \max _{k} \frac{W_{k,t} - \mu _{W_{k,t}}}{\sigma _{W_{k,t}}}, \,\, 1 < k < mn, \end{aligned}$$

where \(\mu _{W_{k,t}} = (t+1)/(6t)\), \(\sigma ^2_{W_{k,t}} = (t+1)[(1-3/4k)t^2 + (1-k)t - k]/ [45t^2(t-k)]\). We conclude that a distributional change has occurred at or before \(V_{t}\), i.e., at or before time \(n\) if

$$\begin{aligned} W_{t} > h_{t} \end{aligned}$$

for suitable chosen threshold \(h_{t}\) to achieve a give IC ARL level. Please note that the change detection starts after \(V_M\) in the numerical studies in this paper. This chart is referred to as RA-CvM hereafter. Implementations of RA-CvM in this paper are performed by the R package ‘cpm’ developed by Ross (2013).

3.2 Numerical comparison of the control charts

In this subsection, we compare the performances of the PROPOSED chart with a few popular ones. The performances of the SPC charts are measured by “out-of-control” (OC) ARL values when “in-control” ARL are controlled at a given level. Shorter the OC-ARL value, better the performance.

First, we focus on scenario (i), i.e., when the mean of the IC distribution changes, but the variance remains unchanged. The IC distribution is chosen to be the standardized version with mean \(0\) and variance \(1\) of the one of the following four distributions: \(N(0, 1)\), \(t(4)\), \(\chi ^2(1)\) and \(\chi ^2(4)\). \(t(4)\) represents symmetric distributions with heavy tails, and \(\chi ^2(1)\) and \(\chi ^2(4)\) represent skewed distributions with different skewness. It is assumed that the pre-specified IC ARL value is \(200\), and the batch size of phase II observations at each time point is \(m=5\).

We compare the “out-of-control” (OC) performance of the related control charts when IC phase I sample size M \(=\) 1000, i.e., \(200 \times 5\). In order to make fair comparisons, we intentionally adjust the control limits of the charts N-CUSUM, EWMA, S-CUSUM, HD-MW and RA-CvM so that their actual IC ARL values equal \(200\) in each of all IC distributions considered. In the step of determining the control limits of all charts except HD-MW and RA-CvM, we simulate phase II data assuming the IC distribution is known. In case of HD-MW and RA-CvM, the control limits, that do not depend on the IC distribution, are used as provided by the R package ‘cpm’. In this study, \(10\) mean shifts ranging from \(-1.0\) to \(1.0\) with step \(0.2\) are considered, representing large, medium and small shifts. Due to the fact that different control charts have different parameters (e.g., \(k_P\) in PROPOSED, \(k_N\) in N-CUSUM, \(\lambda \) in EWMA, and \(k_S\) in S-CUSUM), and that the performances of different charts may not be comparable if their parameters are pre-specified, we use the following approach to set up their parameters. We choose the parameters of all charts to be optimal ones for detecting a given positive shift of size \(0.6\) in each case of the IC distributions, by minimizing the OC ARL values of the charts for detecting that shift while their pre-specified IC ARL values are \(200\), and we use the chosen parameter in all other shifts as well. This approach is widely used in the statistical process control literature (e.g., Qiu and Li (2011)).

Based on 10,000 replications, the OC ARL values of the related control charts, when the procedure parameters are chosen to be the optimal ones for detecting the positive shift of \(0.6\), are shown in Fig. 1. To better demonstrate the difference among different control charts when detecting relatively large shifts, the scale on the y-axis is in natural logarithm. From Fig. 1, we see that the PROPOSED control chart is better than its competitors when the IC distribution is non-normal. When the IC distribution is normal, then the PROPOSED, N-CUSUM, EWMA, HD-MW and RA-CvM charts have comparable OC ARL values when the mean shift is medium or large.

Fig. 1
figure 1

The OC ARL values of six control charts when the IC ARL is \(200\), \(m=5\), \(M=1000\), and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). Tuning parameters are chosen to be the ones that minimize their OC ARL values when detecting the positive mean shift of \(0.6\). Scale on the Y-axis is in natural logarithm. The results are based on \(10,000\) replications

Next, we consider scenario (ii), when the variance of the IC distribution changes, but the mean remains unchanged. As in the previous scenario, the IC distribution is chosen to be the standardized version with mean \(0\) and variance \(1\) of one of the following four distributions: \(N(0, 1)\), \(t(4)\), \(\chi ^2(1)\) and \(\chi ^2(4)\). Similar to scenario (i), it is assumed that the pre-specified IC ARL value is \(200\), and the batch size of phase II observations at each time point is \(m=5\).

We compare the OC performance of the related control charts when the IC sample size M \(=\) 1000. Similar to the previous scenario, we intentionally adjust the control limits of the charts VC-HK, SD-CUSUM and RA-CvM so that their actual IC ARL values equal \(200\) in all cases considered. In this study, \(9\) shifted standard deviations from \(0.2\) to \(2.0\) with step \(0.2\) are considered, representing large, medium and small shifts. Please note that we are considering the OC ARL values when the shifted standard deviations are \(0.2\), \(0.4\), and so on when the IC standard deviation is \(1.0\). Similar to scenario (i), we choose all parameters to be the optimal ones for detecting the particular shift of standard deviation from \(1.0\) to \(1.6\), by minimizing the OC ARL values of the charts for detecting that shift, and we use the chosen parameter in all other shifts as well.

Based on 10,000 replications, the OC ARL values of the related control charts are shown in Fig. 2. In this Figure also, the scale on the y-axis is in natural logarithm, to better demonstrate the difference among different control charts when detecting relatively large shifts. From Fig. 2, we see that the PROPOSED control chart is not performing well when the IC distribution is normal or \(t(4)\). The PROPOSED chart is much better than its competitors when the IC distribution is \(\chi ^2(1)\). When the IC distribution is \(\chi ^2(4)\), then PROPOSED chart detects the reduction in variance well, but can not detect increase in variance very well. The performance of RA-CvM is not good in all cases except \(\chi ^2(1)\). Therefore, if the IC distribution is not highly skewed, and the major anticipated change of IC distribution is in variance, then the PROPOSED chart should not be used.

Fig. 2
figure 2

The OC ARL values of four control charts when the IC ARL is \(200\), \(m=5\), \(M=1000\), and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). Tuning parameters are chosen to be the ones that minimize their OC ARL values when shifted standard deviation is \(1.6\). Scale on the Y-axis is in natural logarithm. The results are based on \(10,000\) replications

Next, we consider scenario (iii), when the skewness of the IC distribution changes with no change in mean and variance. The IC distribution is chosen to be the standardized version with mean \(0\) and variance \(1\) of \(\chi ^2(4)\). Similar to previous simulations, it is assumed that the pre-specified IC ARL value is \(200\), and the batch size of phase II observations at each time point is \(m=5\). The OC performances are studied when the IC distribution changes to the standardized versions of \(\chi ^2\) distributions with various degrees of freedom. The PROPOSED chart is compared with RA-CvM, HD-MW, and two commonly used charts N-CUSUM and VC-HK. Although N-CUSUM and VC-HK are not designed to detect changes in skewness, the purpose of this comparison is to see what happens when a skewness change occurs. From Fig. 3(a), the performances of RA-CvM and HD-MW are comparable with the PROPOSED chart in detecting decrease in skewness. N-CUSUM and VC-HK can not detect skewness changes well if the smaller moments remain unchanged, but the PROPOSED method detects those changes reasonably well. In this study also, the IC sample size is \(M=1000\). Since N-CUSUM and VC-HK are not designed to detect the change of higher moments when mean and variance remain fixed, it is not quite clear how to choose the allowance parameters. For simplicity, the allowance parameters of these two charts are chosen to be the ones as in case (d) of Fig. 1.

Fig. 3
figure 3

The OC ARL values of five control charts when the IC ARL is \(200\), \(m=5,\; M = 1000\), and the actual IC process distribution is the standardized version of \(\chi ^2(4)\) (a) and \(t(4)\) (b). The OC distributions are standardized versions of \(\chi ^2\) and \(t\) with various degrees of freedom as indicated in the labels of X-axes, respectively. The results are based on 10,00 replications

The numerical study on the detection of the change of kurtosis (scenario (iv)) when the mean and variance remain unchanged, is performed similarly. In this example, the IC distribution is the standardized version of \(t(4)\), and the OC distributions are the standardized versions of \(t\)-distributions with various degrees of freedom. From Fig. 3(b), it is clearly seen that N-CUSUM and VC-HK can not detect decrease in kurtosis, but VC-HK can detect one instance of increase in kurtosis. HD-MW and RA-CvM can not detect increase in kurtosis, but can detect decrease in kurtosis to some extent. The PROPOSED chart can detect changes in kurtosis reasonably well. In this comparison also, the allowance parameters of N-CUSUM and VC-HK are chosen to be the ones as in case (b) of Fig. 1. \(t(1)\) and \(t(2)\) are not considered, because they do not have finite variance, and therefore their standardized versions do not exist.

While checking numerical comparisons when M \(=\) 1000, and \(m=1\), we consider only mean shift because this is the most common way the IC distribution changes. Since S-CUSUM is designed for batched data, it is not used in this case. Figure 4 shows that the PROPOSED chart is better than its competitors when the IC distribution is \(\chi ^2(1)\), and comparable to its closest competitors in other cases. In case of \(\chi ^2(1)\), both HD-MW and RA-CvM perform quite well compared to N-CUSUM, EWMA. In this case, since \(m\) is small (equal to 1), the IC ARL of 1000 is considered instead of \(200\). Similar performances are observed when \(M=1000\), and \(m=2\), and the IC ARL is \(500\). Figure 5 presents the performances of the charts in this case.

Fig. 4
figure 4

The OC ARL values of five control charts when the IC ARL is 1000, \(m=1\), M \(=\) 1000, and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). Tuning parameters are chosen to be the ones that minimize their OC ARL values when detecting the positive mean shift of \(0.6\). The results are based on 10,000 replications

Fig. 5
figure 5

The OC ARL values of six control charts when the IC ARL is \(500\), \(m=2\), \(M=1000\), and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). Tuning parameters are chosen to be the ones that minimize their OC ARL values when detecting the positive mean shift of \(0.6\). The results are based on \(10{,}000\) replications

From the simulation studies above, we see that the PROPOSED chart performs well in detecting the mean shift, when the variance remain unchanged. It is much better than its competitors when the IC distribution is highly non-normal. The PROPOSED chart detects changes of variance well when the IC distribution is highly skewed. In all other cases considered, the performances of the PROPOSED chart to detect changes in variance are not good. It is also seen that the PROPOSED chart detects changes in skewness and kurtosis well, and better than commonly used control charts in most cases. Therefore, the PROPOSED chart can be used in many applications except when the major anticipated change of the IC distribution is in variance while the IC distribution is not highly skewed.

The PROPOSED chart can not only detect changes in any particular moment, it can also detect any arbitrary changes in the process distribution. To demonstrate that, following changes in process distribution are considered: (i) changes in rate parameter of exponential distribution, (ii) changes in shape parameter of gamma distribution when the rate parameter is unchanged, (iii) changes in shape parameter of Weibull distribution when the scale parameter is fixed at \(1\), and (iv) changes in the shape parameters of beta distribution. In this example, \(ARL_0=1000\), \(m=1\), \(M=1000\) and the number of replications is \(10{,}000\). To make fair comparisons, the control limits are determined assuming that the corresponding IC distribution is known. Table 1 presents the OC ARL values of HD-MW, RA-CvM and the PROPOSED chart. In each case, the PROPOSED chart either performs similarly with the best competitor(s), or outperforms its closest competitor.

Table 1 The OC ARL values of three control charts for some distributional changes

3.3 More about the proposed control chart

In this section, some discussions about the proposed chart are provided along with a few practical guidelines of its use.

3.3.1 \(h_P\) values in various cases when phase I sample size is large

The control limit \(h_P\) of the PROPOSED chart is provided when \(k_P\) is \(1.0\), \(2.0\), \(3.0\), \(4.0\) or \(5.0\), the batch size is \(1, 5\) or \(10\), pre-specified \(ARL_0\) values are \(100, 200\), \(500\) or 1000, and we have a large number of phase I data. \(h_P\) values are calculated by the procedure described in Section 2. Please note that in this numerical task, phase II quantiles \(\widehat{Q}_j(i)\) are independently generated from \(U[0,1]\), not from explicit phase I data as long as we assume that phase I data-set is large. For practical purposes, we need a few thousand observations in phase I so that we can use the computed \(h_P\) values in Table 2. From that table, we see that \(h_P\) increases with the increase of \(k_P\) for each selected choices of \(m\) and \(ARL_0\). Moreover, as expected, \(h_P\) decreases with the increase of \(ARL_0\), for each case of \(m\) and \(k_P\).

Table 2 The value of the control limit \(h_P\), when \(k_P\) is \(1.0\), \(2.0\), \(3.0\), \(4.0\) or \(5.0\), the batch size is \(1, 5\) or \(10\), and the pre-specified \(ARL_0\) value is \(100\), \(200\), \(500\), or \(1000\)

3.3.2 Choice of \(k_P\) in various practical applications

We compare the OC ARL of the PROPOSED chart when \(m=5\), \(ARL_0=200\) and \(k_P\) is \(1.0\), \(2.0\), \(3.0\), \(4.0\) or \(0.5\), and only the mean of the process distribution changes. In Fig. 6, we can hardly distinguish the lines corresponding to various values of \(k_P\). Therefore, the choice of \(k_P\) within the range of \(1.0\)\(5.0\) does not influence the performance of the PROPOSED chart by much in many applications. Therefore, in a practical application, we do not seem to lose much if we arbitrarily choose \(k_P=3.0\), when \(ARL_0\) is around \(200\) or higher. The results are similar when the distributional change is in either of variance, skewness or kurtosis.

Fig. 6
figure 6

The OC ARL values of the PROPOSED control chart when the value of the tuning parameter \(k_P\) is \(1.0\), \(2.0\), \(3.0\), \(4.0\) or \(5.0\), the IC ARL is \(200\), \(M=1000\), \(m=5\), and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). The results are based on \(10{,}000\) replications. The curves for various \(k_P\) values are hardly distinguishable

3.3.3 Choice of \(h_P\) when phase I sample size is small

When phase I sample size is small, typically around a thousand or less, the computed \(h_P\) values in Table 2 does not produce actual IC ARL. Figure 7 shows that the actual ARL values can be substantially smaller than pre-specified ARL value of \(200\). This is due to the fact that the empirical distribution of \(\widehat{Q}_j(i)\) quantiles calculated from phase I data-set (c.f., expression (1)) differs substantially from \(U[0,1]\). Figure 7 shows that the average detection times for various mean shifts from \(0.2\) through \(1.0\) across various curves for \(M=10{,}000, 1000\), and \(500\) are practically same. However, if phase I sample size is small, and the “in-control” process distribution is unknown, we can simulate phase II data by sampling from phase I sample with replacement. We start with an arbitrary value of \(h_P\) and let the precess run until we get a signal. We repeat this many times, say \(10{,}000\), and calculate the average run length (ARL). We adjust the \(h_P\) value until we get an ARL value that is reasonably close to the pre-specified value. Figure 8 presents the performances of the control charts based on \(10{,}000\) replications when phase I sample size is only \(100\), and we simulated phase II data by this approach. In case of HD-MW and RA-CvM, the control limits, that do not depend on IC distribution, are used as provided by the R package ‘cpm’. In this scenario also, the PROPOSED chart outperforms others in most cases.

Fig. 7
figure 7

The OC ARL values of the PROPOSED control chart when phase I sample size \(M=10{,}000, 1000\), or \(500\), the value of the tuning parameter \(k_P\) is \(0.3\), the IC ARL is \(200\), \(m=5\), and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). The results are based on \(10{,}000\) replications. The curves for various \(k_P\) values are hardly distinguishable when mean shift is larger than or equal to \(0.2\)

Fig. 8
figure 8

The OC ARL values of five control charts when the IC ARL is \(1000\), \(m=1\), \(M=100\), and the actual IC process distribution is the standardized version of \(N(0,1)\) (a), \(t(4)\) (b), \(\chi ^2(1)\) (c), and \(\chi ^2(4)\) (d). Tuning parameters are chosen to be the ones that minimize their OC ARL values when detecting the positive mean shift of \(0.6\). In this simulation, phase II data samples are generated by the method in Sect. 3.3.3. The results are based on \(10{,}000\) replications

3.3.4 Choice of the cut-off value \(0.2\) in \(b(n,p_n,k_P,h_P)\)

Instead of \(0.2\) in \(b(n,p_n,k_P,h_P)\), if we choose a smaller value, say \(0.05\) or \(0.1\), we expect smaller amount of pruning. In that case, there are two major consequences: (i) If a distributional change occurs after a large amount of IC phase II data, the chart requires a large amount of OC data to detect the change. (ii) The computation is more extensive. On the other hand, if we choose a larger value, say \(0.4\), then pruning is expected to be large. If the distributional change is not large, say, only a small shift in mean, pruning can still be large even for such OC data. This can negatively influence the performance of the proposed chart. The performance of the proposed chart is not very sensitive to the choice of the cut-off value between \(0.15\) and \(0.30\).

4 A real-data application

In this section, the proposed SPC chart and relevant other competing SPC charts are applied on a real-data about seasonal snowfall measurements in Minneapolis St. Paul area starting from 1884–1885 season through 2013–2014. Figure 9(a) shows that the seasonal snowfall measurements were quite stable early on until 1965–1966 season, and after that the IC distribution of the seasonal snowfall measurement seems to have changed. The snowfall data were collected from the website of “Minnesota Climatology Working Group” (http://climate.umn.edu/doc/twin_cities/twin_cities.htm). The proposed method, like many other phase II SPC charts, assumes that observations at different time points are independent of each other. Durbin-Watson test using the R function dwtest(.) in the package lmtest (Zeileis and Hothorn 2002) reveals that the annual snowfall values are not significantly autocorrelated. We consider the data from 1884 to 1885 season through 1965–1966, i.e. first \(82\) seasons as phase I IC data. The sample mean and standard deviation of phase I IC data are found to be \(m=41.4293\) and \(s=15.8892\), respectively. For simplicity, we transform all (both phase I and phase II) data by first subtracting \(m\) and then dividing by \(s\), and we call the transformed data by \(Z\). Figure 9(b) presents \(Z\) values sequentially. All \(Z\) data before the time point \(82\), (i.e. until 1965–1966 season) are used as IC phase I data, and rest are used as phase II test data.

Fig. 9
figure 9

a Original observations of the snowfall data. b Transformed data, i.e., \(Z\). c Density histogram, estimated density curve (solid) of the IC phase I data, and the density curve (dotted) of \(N(0,1)\). d Original observations, with the point of signal by the PROPOSED chart. In plots (a), (b) and (d), the vertical dotted lines separate the IC phase I data from phase II test data. In plot (b), the horizontal dotted lines are for \(Z=\pm 1\) lines. In plot (d), the horizontal solid line is for the sample mean of the first \(82\) observations, the horizontal dotted lines are for sample mean \(\pm \) sample standard deviation of those numbers, and the solid vertical line indicates 1978–1979 season when the PROPOSED chart signals

In Figure 9(a, b), the IC phase I data, and the phase II test data are separated by a vertical thick dotted line. From Fig. 9(b), we see that the mean, variance and possibly some higher moments of \(Z\) data changed right after 1965–1966. Table 3 provides these information quantitatively. In this table, seasons until 1983–1984 in phase II data, i.e., until \(100\)-th time point are considered, because from Fig. 9(b) the process distribution seems to have changed again after that time as well. Computations of skewness and kurtosis are done using the R package moments (Komsta and Novomestky 2012).

Table 3 First four sample moments of various segments of \(Z\)

Before applying any SPC chart, we first check the normality of the phase I IC data. Shapiro–Wilk’s test for checking normality gives a p value of \(0.0053\), i.e. the phase I IC data are significantly non-normal. To demonstrate this, the density histogram of the IC data is presented in Fig. 9(c), along with its estimated density curve (solid) and the density curve of the standard normal distribution. Now, we apply N-CUSUM, EWMA, HD-MW, VC-HK, RA-CvM and the PROPOSED chart. Since S-CUSUM is designed for batched data, it is not considered in this single-observation case. Similar to other single-observation scenarios as in Figs. 4 and 8, the pre-specified IC ARL value is \(1000\) in all charts. The allowance parameters of N-CUSUM and EWMA are chosen to be ones that minimizes the OC ARL when there is a positive mean shift of \(0.6\), while the variance remains unchanged. The allowance parameter of VC-HK is chosen to be the one that minimizes the OC ARL when there is a standard deviation increase of \(0.6\), while the mean remains unchanged. While determining the control limits of N-CUSUM, EWMA and VC-HK, the method in Sect. 3.3.3 is applied. N-CUSUM and EWMA signal at time point \(98\), i.e., at 1981–1982 season, VC-HK signals at time point \(100\), i.e., at 1983–1984 season, HD-MW and RA-CvM signal at time point \(96\), i.e., at 1979–1980 season, while the PROPOSED chart signals at time point \(95\), i.e. at 1978–1979 season in both cases when the control limit is determined from Table 2, and by resampling phase I data as suggested in Sect. 3.3.3. Therefore, in this example, the PROPOSED chart signals distributional change earlier than other competing charts.

5 Concluding remarks

In this paper, a new SPC chart is proposed to detect any arbitrary change in univariate process distribution when the process distribution is continuous, and a bunch of “in-control” phase I data are available. From the numerical study and a real data analysis, it is seen that this chart can be used in many applications. Another major contribution of this paper is the idea of pruning parts of phase II data from distant past based on current p values. It is worth trying similar approach to many standard SPC charts (e.g., EWMA chart) when large amount of phase II data are anticipated before a distributional change or phase II data arrive rapidly. If the number of phase I sample is very small, say around \(10\), then \(\text{ ESDQ }(n)\) can have a lot of ties. Since Kolmogorov–Smirnov test can not handle the case when there are lot of ties, this chart is not reliable in this case. One direction of future research is to generalize the proposed chart in a multivariate process.