Movatterモバイル変換


[0]ホーム

URL:


Jump to content
WikipediaThe Free Encyclopedia
Search

Interquartile range

From Wikipedia, the free encyclopedia
Measure of statistical dispersion
"IQR" redirects here. For other uses, seeIQR (disambiguation).
Boxplot (with an interquartile range) and aprobability density function (pdf) of a NormalN(0,σ2) Population

Indescriptive statistics, theinterquartile range (IQR) is a measure ofstatistical dispersion, which is the spread of the data.[1] The IQR may also be called themidspread,middle 50%,fourth spread, orH‑spread. It is defined as the difference between the 75th and 25thpercentiles of the data.[2][3][4] To calculate the IQR, the data set is divided intoquartiles, or four rank-ordered even parts via linear interpolation.[1] These quartiles are denoted byQ1 (also called the lower quartile),Q2 (themedian), andQ3 (also called the upper quartile). The lower quartile corresponds with the 25th percentile and the upper quartile corresponds with the 75th percentile, so IQR =Q3 −  Q1[1].

The IQR is an example of atrimmed estimator, defined as the 25% trimmedrange, which enhances the accuracy of dataset statistics by dropping lower contribution, outlying points.[5] It is also used as arobust measure of scale[5] It can be clearly visualized by the box on abox plot.[1]

Use

[edit]

Unlike totalrange, the interquartile range has abreakdown point of 25%[6] and is thus often preferred to the total range.

The IQR is used to buildbox plots, simple graphical representations of aprobability distribution.

The IQR is used in businesses as a marker for theirincome rates.

For a symmetric distribution (where the median equals themidhinge, the average of the first and third quartiles), half the IQR equals themedian absolute deviation (MAD).

Themedian is the corresponding measure ofcentral tendency.

The IQR can be used to identifyoutliers (seebelow). The IQR also may indicate theskewness of the dataset.[1]

The quartile deviation or semi-interquartile range is defined as half the IQR.[7]

Algorithm

[edit]

The IQR of a set of values is calculated as the difference between the upper and lower quartiles, Q3 and Q1. Each quartile is a median[8] calculated as follows.

Given an even2n or odd2n+1 number of values

first quartile Q1 = median of then smallest values
third quartile Q3 = median of then largest values[8]

Thesecond quartile Q2 is the same as the ordinary median.[8]

Examples

[edit]

Data set in a table

[edit]

The following table has 13 rows, and follows the rules for the odd number of entries.

ix[i]MedianQuartile
17Q2=87
(median of whole table)
Q1=31
(median of lower half, from row 1 to 6)
27
331
431
547
675
787
8115Q3=119
(median of upper half, from row 8 to 13)
9116
10119
11119
12155
13177

For the data in this table the interquartile range is IQR = Q3 − Q1 = 119 - 31 = 88.

Data set in a plain-text box plot

[edit]
                             +−−−−−+−+               * |−−−−−−−−−−−|     | |−−−−−−−−−−−|                             +−−−−−+−+ +−−−+−−−+−−−+−−−+−−−+−−−+−−−+−−−+−−−+−−−+−−−+−−−+   Number line 0   1   2   3   4   5   6   7   8   9   10  11  12

For the data set in thisbox plot:

  • Lower (first) quartileQ1 = 7
  • Median (second quartile)Q2 = 8.5
  • Upper (third) quartileQ3 = 9
  • Interquartile range, IQR =Q3 -Q1 = 2
  • Lower 1.5*IQR whisker =Q1 - 1.5 * IQR = 7 - 3 = 4. (If there is no data point at 4, then the lowest point greater than 4.)
  • Upper 1.5*IQR whisker =Q3 + 1.5 * IQR = 9 + 3 = 12. (If there is no data point at 12, then the highest point less than 12.)
  • Pattern of latter two bullet points: If there are no data points at the true quartiles, use data points slightly "inland" (closer to the median) from the actual quartiles.

This means the 1.5*IQR whiskers can be uneven in lengths. The median, minimum, maximum, and the first and third quartile constitute theFive-number summary.[9]

Distributions

[edit]

The interquartile range of a continuous distribution can be calculated by integrating theprobability density function (which yields thecumulative distribution function—any other means of calculating the CDF will also work). The lower quartile,Q1, is a number such that integral of the PDF from -∞ toQ1 equals 0.25, while the upper quartile,Q3, is such a number that the integral from -∞ toQ3 equals 0.75; in terms of the CDF, the quartiles can be defined as follows:

Q1=CDF1(0.25),{\displaystyle Q_{1}={\text{CDF}}^{-1}(0.25),}
Q3=CDF1(0.75),{\displaystyle Q_{3}={\text{CDF}}^{-1}(0.75),}

where CDF−1 is thequantile function.

The interquartile range and median of some common distributions are shown below

DistributionMedianIQR
Normalμ2 Φ−1(0.75)σ ≈ 1.349σ ≈ (27/20)σ
Laplaceμ2b ln(2) ≈ 1.386b
Cauchyμ

Interquartile range test for normality of distribution

[edit]

The IQR,mean, andstandard deviation of a populationP can be used in a simple test of whether or notP isnormally distributed, or Gaussian. IfP is normally distributed, then thestandard score of the first quartile,z1, is −0.67, and the standard score of the third quartile,z3, is +0.67. Givenmean = P¯{\displaystyle {\bar {P}}} andstandard deviation = σ forP, ifP is normally distributed, the first quartile

Q1=(σz1)+P¯{\displaystyle Q_{1}=(\sigma \,z_{1})+{\bar {P}}}

and the third quartile

Q3=(σz3)+P¯{\displaystyle Q_{3}=(\sigma \,z_{3})+{\bar {P}}}

If the actual values of the first or third quartiles differ substantially[clarification needed] from the calculated values,P is not normally distributed. However, a normal distribution can be trivially perturbed to maintain its Q1 and Q2 std. scores at 0.67 and −0.67 and not be normally distributed (so the above test would produce a false positive). A better test of normality, such asQ–Q plot would be indicated here.

Outliers

[edit]
Box-and-whisker plot with four mild outliers and one extreme outlier. In this chart, outliers are defined as mild above Q3 + 1.5 IQR and extreme above Q3 + 3 IQR.

The interquartile range is often used to findoutliers in data. Outliers here are defined as observations that fall below Q1 − 1.5 IQR or above Q3 + 1.5 IQR. In a boxplot, the highest and lowest occurring value within this limit are indicated bywhiskers of the box (frequently with an additional bar at the end of the whisker) and any outliers as individual points.

See also

[edit]

References

[edit]
  1. ^abcdeDekking, Frederik Michel; Kraaikamp, Cornelis; Lopuhaä, Hen Paul; Meester, Ludolf Erwin (2005).A Modern Introduction to Probability and Statistics. Springer Texts in Statistics. London: Springer London.doi:10.1007/1-84628-168-7.ISBN 978-1-85233-896-1.
  2. ^Upton, Graham; Cook, Ian (1996).Understanding Statistics. Oxford University Press. p. 55.ISBN 0-19-914391-9.
  3. ^Zwillinger, D., Kokoska, S. (2000)CRC Standard Probability and Statistics Tables and Formulae, CRC Press.ISBN 1-58488-059-7 page 18.
  4. ^Ross, Sheldon (2010).Introductory Statistics. Burlington, MA: Elsevier. pp. 103–104.ISBN 978-0-12-374388-6.
  5. ^abKaltenbach, Hans-Michael (2012).A concise guide to statistics. Heidelberg: Springer.ISBN 978-3-642-23502-3.OCLC 763157853.
  6. ^Rousseeuw, Peter J.; Croux, Christophe (1992). Y. Dodge (ed.)."Explicit Scale Estimators with High Breakdown Point"(PDF).L1-Statistical Analysis and Related Methods. Amsterdam: North-Holland. pp. 77–92.
  7. ^Yule, G. Udny (1911).An Introduction to the Theory of Statistics. Charles Griffin and Company. pp. 147–148.
  8. ^abcBertil., Westergren (1988).Beta [beta] mathematics handbook : concepts, theorems, methods, algorithms, formulas, graphs, tables.Studentlitteratur. p. 348.ISBN 9144250517.OCLC 18454776.
  9. ^Dekking, Kraaikamp, Lopuhaä & Meester, pp. 235–237

External links

[edit]
Continuous data
Center
Dispersion
Shape
Count data
Summary tables
Dependence
Graphics
Study design
Survey methodology
Controlled experiments
Adaptive designs
Observational studies
Statistical theory
Frequentist inference
Point estimation
Interval estimation
Testing hypotheses
Parametric tests
Specific tests
Goodness of fit
Rank statistics
Bayesian inference
Correlation
Regression analysis
Linear regression
Non-standard predictors
Generalized linear model
Partition of variance
Categorical
Multivariate
Time-series
General
Specific tests
Time domain
Frequency domain
Survival
Survival function
Hazard function
Test
Biostatistics
Engineering statistics
Social statistics
Spatial statistics
Retrieved from "https://en.wikipedia.org/w/index.php?title=Interquartile_range&oldid=1322896771"
Category:
Hidden categories:

[8]ページ先頭

©2009-2026 Movatter.jp