Skip to main content

Outlier Detection using Projection Quantile Regression for Mass Spectrometry Data with Low Replication

Abstract

Background

Mass spectrometry (MS) data are often generated from various biological or chemical experiments and there may exist outlying observations, which are extreme due to technical reasons. The determination of outlying observations is important in the analysis of replicated MS data because elaborate pre-processing is essential for successful analysis with reliable results and manual outlier detection as one of pre-processing steps is time-consuming. The heterogeneity of variability and low replication are often obstacles to successful analysis, including outlier detection. Existing approaches, which assume constant variability, can generate many false positives (outliers) and/or false negatives (non-outliers). Thus, a more powerful and accurate approach is needed to account for the heterogeneity of variability and low replication.

Findings

We proposed an outlier detection algorithm using projection and quantile regression in MS data from multiple experiments. The performance of the algorithm and program was demonstrated by using both simulated and real-life data. The projection approach with linear, nonlinear, or nonparametric quantile regression was appropriate in heterogeneous high-throughput data with low replication.

Conclusion

Various quantile regression approaches combined with projection were proposed for detecting outliers. The choice among linear, nonlinear, and nonparametric regressions is dependent on the degree of heterogeneity of the data. The proposed approach was illustrated with MS data with two or more replicates.

Findings

Background

Mass spectrometry (MS) data are often generated from various biological or chemical experiments. Such vast data is usually analyzed automatically in a computer process consisting of pre-processing, significance test, classification, and clustering. Elaborate pre-processing is essential for successful analysis with reliable results. One pre-processing step is required to detect outliers, which which are extreme due to technical reasons. The plausible outlying observations detected can be examined carefully, and then corrected or eliminated if necessary. However, as the manual examination of all observations for outlier detection is time-consuming, plausible outlying observations must be detected automatically.

Identification of statistical outliers is the subject of some controversy in statistics[1]. Several outlier detection algorithms have been proposed for univariate data, including Grubbs’ test[2] and Dixon’s Q test[3]. These tests were designed to analyze data under the normality assumption, so that they may produce unreliable outcomes in the case of few replicates. Furthermore, they are not applicable for duplicated samples. Another naive approach to detect outliers statistically constructs lower and upper fences of differences between two samples, Q1 - 1.5 IQR and Q3 + 1.5 IQR, where Q1 is the lower 25% quantile, Q3 is the upper 25% quantile, and IQR = Q3 - Q1. They are claimed to be outliers if they are smaller than the lower fence or larger than the upper fence. However, this may generate a spurious result because variability is heterogeneous in high-throughput data even generated from MS experiments.

Figure1 shows the log-scale scatter plot of the technically duplicated samples under the same biological condition from a MS experiment. The variability differs according to the intensity levels in the plot, so that the naive outlier detection method, ignoring the heterogeneity of variability, may often miss true outliers at high levels and select false outliers at low levels. If a number of technical replicates for each peptide under the same biological condition can be obtained in MS experiments, the examination of outliers can be conducted for each peptide. However, a small number of replicates is usually conducted for MS experiments due to the high cost of experiments and the limited supply of biological samples.

Figure 1
figure 1

Scatter plot of duplicate samples. File: Scatter.pdf - Scatter plot of duplicate samples after log2 transformation from mass spectrometry proteomics data.

Cho et al.[4] proposed a more elaborate approach for detecting outliers with low false positive and negative rates in MS data to solve the problem when the number of technical replicates is two. The algorithm was developed by utilizing quantile regression for duplicate MS experiments. The R package (called OutlierD) that was also developed can only be used for duplicate experiments. Therefore, we here propose a new outlier detection algorithm for multiple high-throughput experiments, particularly those with few, but more than two replicates.

Classical Approaches

Suppose that there are n replicated samples and p peptides in MS data. Then let x ij be the i th replicated sample from experiments under the same biological or experimental condition, where i = 1,…,n and j = 1,…,p. For convenience, let y ij = log 2 ( x ij ). Typically, n is small and p is very large in high-throughput data, i.e., p >> n. In addition, let y(1)j ≤ y(2)j≤⋯≤ y(n)j be ordered samples for peptide j, where y ( 1 ) j = min 1 ≤ i ≤ n y ij and y ( n ) j = max 1 ≤ i ≤ n y ij , the smallest and the largest observations, respectively.

Outliers are often detected by the classical approaches such as Dixon’s Range Test and Grubbs test. Dixon’s Range Test, also known as Dixon’s Q-test[3], utilizes order statistics as follows.

Q j = ( y ( 2 ) j − y ( 1 ) j ) ( y ( n ) j − y ( 1 ) j ) or ( y ( n ) j − y ( n − 1 ) j ) ( y ( n ) j − y ( 1 ) j ) .
(1)

The denominator is the difference between the largest and smallest observations and the numerator is the difference between the smallest two values or the largest two values. If the test statistic Q j is smaller than the critical value given by Rorabacher[5], peptide j is flagged as an outlier. If n = 2, the statistic is always 1; thus, this test is applicable for n ≥ 3.

Grubbs’ test[2, 6] also utilizes order statistics and its test statistic is defined as follows.

T nj = ( y ( n ) j − y ̄ · j ) s j and T 1 j = ( y ̄ · j − y ( 1 ) j ) s j ,
(2)

where y ̄ · j is the sample mean and s j the standard deviation for peptide j. The denominator is the standard deviation and the numerator is the difference between the smallest (or largest) value and the sample mean. If T nj or T1j is smaller than the critical value, peptide j is flagged as an outlier. If n = 2, the statistic is always1/ 2 ; thus, this test is also applicable for n ≥ 3.

Proposed Methods

In duplicated experiments (n = 2), two observed values, x1j and x2j for each j, should be theoretically identical, but are not identical in practice due to their variability. Even though they are not identical, they should not differ substantially. The tolerance of the difference between the two observed values from the same condition is not constant because their variability is heterogeneous. The variability of high-throughput data depends on intensity levels.

Cho et al.[4] proposed the construction of lower and upper fences using quantile regression in an MA plot with M and A values in vertical and horizontal axes, respectively, where M j is the difference between replicated samples for j and A j is the average, i.e. M j = y 1 j − y 2 j = log 2 ( x 1 j / x 2 j ) and A j =( y 1 j + y 2 j )/2=(1/2) log 2 ( x 1 j x 2 j ) to detect the outliers accounting for the heterogeneity of variability.

In multiple experiments (n ≥ 2), it is natural to investigate outliers based on all observed values in a high-dimensional space. An outlier will be a very large distance from the center of the distribution of a peptide. The cutoffs of distances for classification of outliers depend on the degree of variability from the center. The degree of variability is dependent on intensity levels and the center can be defined as the 45° line from the origin. More flexibly, the center can be obtained by principal component analysis (PCA), as seen in Figure2. The first principal component (PC) becomes the center of each intensity level, i.e., a new axis for intensity levels. The experiments are replicated under the same biological and technical condition; hence, most variation can be explained by the first PC. It implies that it is enough to use the first PC practically. An outlier will have a large distance from its projection. Following the notations for applying quantile regression, we can define the distance of peptide j to the projection as M j and the length of the projection on the new axis as A j . Then the first and third quantiles can be obtained by applying quantile regression on an MA plot with M and A in the vertical and horizontal axes, repectively; hence, the upper and lower fences can be constructed to classify the outliers.

Figure 2
figure 2

Outlier detection using projection quantile regression. File: MA.pdf - Outlier detection using projection quantile regression for mass spectrometry data. The dotted lines represent Q3(A) and the solid lines represent upper fences classifying outliers and non-outliers.

Describing this projection approach in more detail, we first subtract the sample mean of each sample from each observation to shift the sample mean to the origin because the PC go through the sample means. The first PC vector v can be found on the new sample space from y 1 ∗ ,…, y n ∗ and the projection of each peptide on the vector v can be obtained. Then, we can calculate the length of the projection,| y j ∗ ′ v|/ v ′ v , and the length of the difference between a vector of peptide j and the projection,| y j ∗ −( y j ∗ ′ v/ v ′ v)v|. The length of the projection is multiplied by the sign of y j ∗ ′ v to distinguish the positive and negative directions. The signed length of the project and the length of the difference are defined as A j and M j of peptide j, respectively. Outlying peptides will have unduly large M values. Judging whether it is undue or not depends on A j because the variability of M values is heterogeneous. Like OutlierD, we obtain first and third quantiles, Q1 and Q1, depending on intensity levels, and then construct the upper and lower fences to classify outliers from normal observations. Quantile regression[7] is utilized on an MA plot to obtain the first and third quantile estimates, Q1(A) and Q3(A), respectively, depending on the intensity levels A. The q-quantile linear quantile regression with {(A j M j ),j = 1,…,p} is used to find the parameters minimizing

∑ { j : M j ≥ g ( A j ; θ 0 , θ 1 ) } q | M j − g ( A j ; θ 0 , θ 1 ) | + ∑ { j : M j < g ( A j ; θ 0 , θ 1 ) } ( 1 − q ) | M j − g ( A j ; θ 0 , θ 1 ) |
(3)

where 0 < q < 1, and g(A j ;θ0θ1) = θ0 + θ1A j . Using Equation (3), the 0.25 and 0.75 quantile estimates, Q1(A) and Q3(A), are calculated depending on the levels A. Then, the lower and upper fences are constructed: Q1(A) - kIQR(A) and Q3(A) + kIQR(A), where IQR(A) = Q3(A) - Q1(A) and k is a tuning parameter. We set k to 1.5 as the default value in our algorithm and software program because the value is practically often used. A larger k value selects fewer peptides, while a smaller k selects more outliers. The value can be adjusted empirically according to the magnitude of the variation of the data.

We can obtain more flexible quantile estimates by nonlinear and nonparametric quantile regression approaches[8]. For nonlinear quantile regression, the asymptotic function[9] can be employed:

g ( A j ; θ 1 , θ 2 , θ 3 ) = θ 1 { 1 − exp [ − exp ( θ 2 ) × ( A j − θ 3 ) ] } ,
(4)

where θ1 is the asymptote, θ2 is the log rate, and θ3 is the value of A at which the response becomes zero. In addition, Self-starting, Frank, Asymptotic with Offset and Copula functions can be employed. For nonparametric quantile regression, we utilize smoothing spline with the total variation regularization for univariate data to our algorithm[10]. A smoothing parameter plays a role in adjusting the degree of smoothness. We set it to 1 as the default, but it can be changed by users. The algorithm using projection can be summarized as follows.

Proposed Algorithm

  1. 1.

    Shift the sample means ( y ̄ 1 ,…, y ̄ n ) to the origin (0,…,0), i.e., y ij ∗ = y ij − y ̄ i .

  2. 2.

    Find the first PC vector v using PCA on the space of y 1 ∗ ,…, y n ∗ .

  3. 3.

    Obtain the projection of a vector y j ∗ =( y 1 j ∗ ,…, y nj ∗ ) of each peptide j on v, where j = 1,…,p.

  4. 4.

    Compute the signed length of the projection A j =sign( y j ∗ ′ v)| y j ∗ ′ v|/ v ′ v and the length of the difference between a vector of peptide j and the projection M j =| y j ∗ −( y j ∗ ′ v/ v ′ v)v|, where j = 1,2,…,p.

  5. 5.

    Obtain the first and third quantile values Q 1(A) and Q 3(A), on an MA plot using a quantile regression approach. Then calculate IQR(A) = Q 3(A)−Q 1(A).

  6. 6.

    Construct the lower and upper fences, LB(A) = Q 1(A) - k IQR(A) and UB(A) = Q 3(A) + k IQR(A), where k is a tuning parameter.

  7. 7.

    Declare peptide j as an outlier if it is located above the upper fence or under the lower fence.

This projection approach utilizes all the replicates simultaneously, and a high-dimensional problem reduces to two-dimensional one that can easily be solved. Shifts from biased experiments can be ignored due to the use of PCA.

Results and discussion

We conducted a simulation study to investigate the performance of the proposed approaches. We also applied it to real-life data with three replicates of liquid chromatography/tandem MS (LC-MS/MS) experiments.

Simulated data

Suppose that there are replicated samples with p = 1000 peptides. We considered two or more replicates, i.e., n ≥ 2. Assimilating reality, we first drew the means μ j from U(5,35) and computed the variances σ j 2 with the following relationships between the mean μ and variance σ2.

Constant : σ j = 1 Linear : σ j = − ( μ j − 5 ) / 10 + 3 Nonlinear : σ j = exp ( 2 − μ j / 10 ) Nonparametric : σ j = exp ( 2 − μ j / 10 ) + ( 2 B j − 1 ) Z j
(5)

where B j ∼Bernoulli(1/2) and Z j ∼N(1/μ j ,0.01). The relationships between the means and the variances are shown in Figure3. For 950 non-outliers (j = 1,…,950), we assumed that Y ij ∼N( μ j , σ j 2 ) for i = 1,…,n. For 50 outliers (j = 951,…,1000), we assumed that Y ij ∼N( μ j ′ , σ j 2 ) for one of the samples and Y ij ∼N( μ j , σ j 2 ) for the other samples, where μ j ∼ U(5,35) and μ j ′ =μ j + (2B j −1)U(1,2) for constant variance and μ j ′ = μ j + (2B j −1)(120/μ j )U(1,2) for other variances. Thus, an artificial data set for each n was generated with 950 non-outliers and 50 outliers. Then, the data were used to check the sensitivities (the probabilities of detecting outliers correctly), specificities (the probabilities of detecting non-outliers correctly), and accuracies (the probabilities of detecting outliers or non-outliers correctly) of the quantile and projection quantile approaches for n = 2 and the Dixon test, Grubbs’s test, and projection quantile approaches for n = 3,…,8. Constant, linear, nonlinear, and nonparametric quantile regressions were accounted for the quantile and projection quantile approaches. This procedure was repeated 1000 times independently.

Figure 3
figure 3

Relationship between mean and variance for simulated data. File: Var.pdf - Constant, linear, nonlinear, and nonparametric relationship between μ and σ to generate the simulated data.

Table1 presents the sensitivities, specificities, and accuracies of the quantile and projection quantile methods for the simulated data from duplicated experiments (n = 2) and Figure4 shows their confidence intervals. The classical methods were not applied because they work only for n > 2. Under the constant variance, all the methods performed well. Under the linear, nonlinear, and nonparametric variances, the quantile and projection quantile methods with constant quantile regression performed worse than those with the other quantile regression due to the heterogeneity of the variability, as shown in Cho et al.[4]. When comparing the quantile and projection quantile methods, the latter sometimes had somewhat lower sensitivities than the former. However, the quantile and projection quantile methods are mostly comparable.

Table 1 Sensitivities, specificities, and accuracies of the quantile and projection quantile methods for the simulated data from duplicated experiments
Figure 4
figure 4

Confidence intervals of the sensitivities, specificities, and accuracies for duplicate experiments. File: CI2.pdf - Mean plus or minus one standard error of the sensitivities, specificities, and accuracies of the quantile and projection quantile methods for the simulated data from two experiments (n = 2).

Table2 presents the sensitivities, specificities, and accuracies of the classical and projection quantile methods for the simulated data from three to eight experiments (3 ≤ n ≤ 8) and Additional File1 shows their confidence intervals. The results are not shown for n ≥ 9. With multiple experiments, the projection quantile methods with constant, linear, nonlinear, and nonparametric quantile regression performed like those with duplicated experiments. When n = 3, the classical methods had very low sensitivities, resulting in the lower accuracies. With increasing n, the sensitivities of the classical methods increased. When n = 7 or 8, Glubbs’ test was comparable to the projection quantile methods with linear, nonlinear, and nonparametric quantile regression. This implies that the classical methods require a sufficiently large number of replicates. In reality, experiments are often repeated three or more times; thus, the projection quantile method is practically very useful.

Table 2 Sensitivities, specificities, and accuracies of the classical and projection quantile methods for the simulated data from multiple experiments

Real-life data

We here illustrate the projection quantile approach with real-life data obtained from three replicates of LC/MS/MS experiments with 922 peptides (n = 3 and p = 922). The details of the experiments can be found in Min et al.[11] and Cho et al.[4]. Here, the primary goal of the analysis is to detect outliers automatically in the pre-processing step prior to further analysis.

To use the projection approach, we first investigate how much the first PC explains the variation in the data. The first PC takes 96.9% of the variation and the second and third PCs take 1.73% and 1.34%, respectively. This supports that it is enough to use only the first PC. The projection approach with constant, linear, nonlinear, and nonparametric quantile regression selected 74, 69, 99, and 67, respectively. The 3-D scatter plot of the data, shown in Figure5, revealed the variability of the data to be heterogeneous. Constant quantile regression tended to select more peptides at low levels as outliers, whereas the others selected more peptides at the higher levels.

Figure 5
figure 5

3-D Scatter plot of LC/MS data with three replicates. File: Scatter3d.png - Scatter plot of LC/MS data with three replicates; The straight line at the center is the first PC vector. C = Contant, L = Linear, NL = Nonlinear, NP = Nonparametric.

This implies that the projection approach assuming a constant variance can generate many false positives and/or false negatives and, therefore, that more flexible quantile regression is more appropriate than constant quantile regression.

Conclusion

We propose an approach for detecting outliers automatically in low replicated, high-throughput data generated from MS experiments. Because of the practical problems such as cost and time, LC/MS data is usually generated by repeating the experiment three or four times under the same technical or biological condition. Outliers can be investigated within each peptide when there are many replicates; however, within-peptide approaches such as Dixon and Grubbs’ tests are crude in the case of few replicates. A quantile regression approach on an MA plot was proposed in Cho et al.[4] when there are only two replicates. Thus, our proposed method can be used when there are two or somewhat more replicates.

The projection approach using various quantile regressions was examined for outlier detection. The projection approach with linear, nonlinear, or nonparametric quantile regression was more appropriate than the others in heterogeneous high-throughput data. The choice among linear, nonlinear, and nonparametric is dependent on the degree of heterogeneity of the data. In addition, our software program provides a number of options. A single method may not be the best in any situation. Therefore, the data can be applied empirically with various options. Moreover, experimental confirmation is needed after applying our automatic outlier detection. Nevertheless, it is useful because manual examination of all observations is time-consuming without pre-screening.

Availability and Requirements

Project name: Outlier Detection for Mass Spectrometry

Project homepage: http://statlab.korea.ac.kr/OutlierDM/

Operating system(s): Windows, Unix-like systems (Linux, Mac OS X)

Programming language: R (the version of R should be ¿ = 2.14.0)

License: GNU GPL version 2 or later

Author’s contributions

Cho designed and directed this research. Eo wrote and optimized the R code and maintained the software program. Cho and Eo wrote the manuscript. All authors contributed ideas, and read and approved the manuscript.

References

  1. Barnett V, Lewis T: Outliers in Statistical Data. 1984, Hoboken, NJ, USA: Wiley Series in Probability & Statistics, John Wiley & Sons

    Google Scholar 

  2. Grubbs FE: Sample criteria for testing outlying observations. The Annals of Mathematical Statistics. 1950, 21: 27-58. 10.1214/aoms/1177729885.

    Article  Google Scholar 

  3. Dixon WJ: Analysis of extreme values. The Annals of Mathematical Statistics. 1950, 21: 488-506. 10.1214/aoms/1177729747.

    Article  Google Scholar 

  4. Cho H, Kim YJ, Jung HJ, Lee SW, Lee JW: OutlierD: an R package for outlier detection using quantile regression on mass spectrometry data. Bioinformatics. 2008, 24 (6): 882-884. 10.1093/bioinformatics/btn012.

    Article  PubMed  CAS  Google Scholar 

  5. Rorabacher DB: Statistical Treatment for Rejection of Deviant Values: Critical Values for Dixon’s Q parameter and Related Subrange Ratios at the 95% Confidence Level. Anal Chem. 1991, 63: 139-146. 10.1021/ac00002a010.

    Article  CAS  Google Scholar 

  6. Grubbs FE: Procedures for Detecting Outlying Observations in Samples. Technometrics. 1969, 11: 1-21. 10.1080/00401706.1969.10490657.

    Article  Google Scholar 

  7. Koenker R, Bassett G: Regression quantiles. Econometrics. 1978, 46: 33-50. 10.2307/1913643.

    Article  Google Scholar 

  8. Koenker R: Quantile Regression. 2005, Cambridge, United Kingdom: Econometric Society Monograph Series, Cambridge University Press

    Book  Google Scholar 

  9. R Development Core Team: R: A Language and Environment for Statistical Computing. 2011, Vienna, Austria: R Foundation for Statistical Computing, [ISBN 3-900051-07-0]. [http://www.R-project.org/],

    Google Scholar 

  10. Koenker R, Ng P, Portnoy S: Quantile Smoothing Splines. Biometrika. 1994, 81: 673-680. 10.1093/biomet/81.4.673.

    Article  Google Scholar 

  11. Min HK, Hyung SW, Shin JW, Nam HS, Ahm SH, Jung HJ, Lee SW: Ultrahigh-pressure dual online solid phase extraction/capillary reverse-phase liquid chromatography/tandem mass spectrometry (DO-SPE/cRPLC/MS/MS): A versatile separation platform for high-throughput and highly sensitive proteomic analyses. Electrophoresis. 2007, 28: 1012-1021. 10.1002/elps.200600501.

    Article  PubMed  CAS  Google Scholar 

Download references

Acknowledgements

This research was supported by the Basic Science Research Program through the National Research Foundation of Korea (NRF) funded by the Ministry of Education, Science and Technology (2010-0007936).

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to HyungJun Cho.

Additional information

Competing interests

The authors declare that they have no competing interests.

Electronic supplementary material

13104_2012_1809_MOESM1_ESM.pdf

Additional file 1: Confidence intervals of the sensitivities, specificities, and accuracies for multiple experiments. File: CI3.pdf - Mean plus or minus one standard error of the sensitivities, specificities, and accuracies of the classical and projection quantile methods for the simulated data from multiple experiments (3 ≤ n ≤ 8). (PDF 58 KB)

Authors’ original submitted files for images

Rights and permissions

Open Access This article is published under license to BioMed Central Ltd. This is an Open Access article is distributed under the terms of the Creative Commons Attribution License ( https://creativecommons.org/licenses/by/2.0 ), which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.

Reprints and permissions

About this article

Cite this article

Eo, SH., Pak, D., Choi, J. et al. Outlier Detection using Projection Quantile Regression for Mass Spectrometry Data with Low Replication. BMC Res Notes 5, 236 (2012). https://doi.org/10.1186/1756-0500-5-236

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: https://doi.org/10.1186/1756-0500-5-236

Keywords