We propose a new threshold selection method for nonparametric
estimation of the extremal index of stochastic processes. The discrepancy method was proposed as a data-driven smoothing tool
for estimation of a probability density function. Now it is modified
to select a threshold parameter of an extremal index estimator. A
modification of the discrepancy statistic based on the Cramér–von
Mises–Smirnov statistic ω2 is calculated by k largest order statistics
instead of an entire sample. Its asymptotic distribution as k → ∞ is
proved to coincide with the ω2-distribution. Its quantiles are used
as discrepancy values. The convergence rate of an extremal index
estimate coupled with the discrepancy method is derived. The discrepancy method is used as an automatic threshold selection for the
intervals and K-gaps estimators. It may be applied to other estimators
of the extremal index. The performance of our method is evaluated
by simulated and real data examples.