ms_stat: Max-sum (MS) test statistic to identify dragon kings (DKs)

Description Usage Arguments Value References Examples

Description

ms_stat calculates the MS test statistic to determine whether there is significant support for the existence of r DKs in vals. This statistic is less susceptible to swamping, but is also less powerful in the case of clustered outliers, in comparison to the SS and SRS test statistics.

Usage

1
ms_stat(vals, r)

Arguments

vals

numeric vector with at least 3 elements

r

integer indicating number of DKs in vals

Value

MS test statistic

References

Wheatley S, Sornette D (2015). Multiple outlier detection in samples with exponential & pareto tails: Redeeming the inward approach & detecting dragon kings. Swiss Finance Institute Research Paper Series No. 15-28. <doi:10.2139/ssrn.2645709>

Hawkins DM (1980). Identification of outliers, vol. 11. Chapman and Hall. ISBN: 9789401539944

Kimber AC (1982). Tests for many outliers in an exponential sample. Appl Statist, 31(3): 263-71. <doi:10.2307/2348000>

Examples

1
2
3
4
5
6
# generate a numeric vector with DKs
temp <- c(rexp(100),   # exponentially distributed RV
          15, 15, 15)  # DK elements

# calculate test statistic for DKs
ms_stat(temp, r = 3)

dragonking documentation built on May 2, 2019, 4:21 a.m.