Percentile Calculator

Find a percentile value using inclusive linear interpolation (R type 7), with its sorted zero-based index shown.

Enter a percentile from 0 to 100. This tool finds a value at that percentile; it does not calculate the percentile rank of a supplied value. Use comma, space or newline separators. Maximum 1,000 observations; magnitudes ≤ 1e12 and nonzero magnitudes ≥ 1e-12.

Your observations are calculated in this browser and are not uploaded.

Percentile Calculator: what the result means

Find a percentile value using inclusive linear interpolation (R type 7), with its sorted zero-based index shown.

Choose inputs and convention

Enter a percentile from 0 to 100. This tool finds a value at that percentile; it does not calculate the percentile rank of a supplied value. Paste observations into Numeric observations, separated by commas, whitespace or newlines. Keep repeated observations; they contribute to the calculation. Choose Calculate, or load the example to replace the current inputs with the case below.

Worked example

For 0, 10, 20, 30 at the 25th percentile, zero-based index is (4 − 1) × 0.25 = 0.75. Interpolating 75% of the way from 0 to 10 gives 7.5.

Calculation rule

Sort the n observations and compute h = (n − 1)p/100. If h is an integer, select that zero-based position. Otherwise interpolate between the two adjacent sorted values using the fractional part of h. The 0th percentile is the minimum and the 100th is the maximum.

The interpolation convention follows R’s quantile documentation, type 7. Choose the same convention when comparing another tool.

Interpretation and limitations

Percentile conventions differ. Nearest-rank, exclusive interpolation and other methods can give different results on the same small sample. This page implements R type 7 only. One observation returns that value for every supported percentile; duplicate observations remain in the sample.

Numeric bounds and precision

Interpolation uses the parsed numeric values, not rounded display strings. Decimal text is represented as browser floating-point numbers, so values closer than its precision may become indistinguishable. Calculated values are shown to 12 significant digits. Inputs may include signs, decimal points or exponent notation such as 1e3, but not unit suffixes or thousands separators. Up to 1,000 observations and 100,000 characters are accepted; absolute values must be at most 1e12 and nonzero magnitudes at least 1e-12. Zero is valid. Empty comma fields are rejected rather than silently converted to zero.

Editing an input or option clears the previous answer. Copy results copies the displayed summary; calculate again after edits.

Use Quartile Calculator to compare the 25th, 50th and 75th percentiles together.