Skip to content
(1 found this helpful)

Quartile Calculator

This calculator computes the first quartile (Q1), second quartile (Q2 or median), third quartile (Q3), and the interquartile range (IQR) of any dataset. Enter the raw data values as comma, space, or tab-separated values and click the “Calculate” button. The calculator will instantly return the results with a clear, step-by-step solution.

Enter your data values separated by commas, spaces, or tabs (you can copy-paste from Excel).

Want to get the five-number summary statistics instead? Use the 5-number summary calculator.

How to Use the Quartile Calculator

This calculator helps you find the quartiles (Q1, Q2, Q3) and the interquartile range (IQR) for any data. Just follow these simple steps:

  1. Enter the raw data in the input field, either as comma, space, or tab-separated values. You can also copy-paste values directly from Excel.
  2. Click the “Calculate” button

The calculator will instantly return the lower quartile (Q1), the median (Q2), the upper quartile (Q3), and the IQR. It will also present you with a step-by-step solution section to help you learn how to find the quartiles and IQR manually.

What Are Quartiles?

Quartiles are statistical values that divide a dataset into four equal parts after arranging the data in ascending order. They are useful in measuring the center, spread, and skewness of data. The three main types of quartiles are:

  • First Quartile (Q1). This is also known as the lower quartile or the 25th percentile. 25% of the data points fall below this value.
  • Second Quartile (Q2). This is the median or the 50th percentile of the data. It divides the data into two halves. In other words, 50% of the data fall below the second quartile.
  • Third Quartile (Q3). This is also called the upper quartile or the 75th percentile. 75% of the data points fall below this value.

Note. You can easily find the interquartile range (IQR) by subtracting the lower quartile (Q1) from the upper quartile (Q3). That is, IQR = Q3 – Q1.

How to Calculate the Quartiles: Step-by-Step

To calculate Q1, Q2, and Q3 manually, follow these steps:

  1. Arrange the dataset from smallest to largest.
  2. Find the median of the data. This is the second Quartile (Q2)
  3. Split the dataset into two halves at Q2
  4. Find the median of the lower half of the data. This is the first quartile (Q1)
  5. Find the median of the upper half of the data. This is the third quartile (Q3)

Recall. If there is an odd number of observations, the median is the middle number. However, if the number of observations is even, the median is the average of the two middle numbers.

Example 1. When n is Odd

Find the first, second, third, and interquartile range of the following dataset.

Data: 26, 70, 37, 47, 31, 45, 43, 42, 44, 48, 35

Solution

Step 1. Arrange the data set from the smallest to the largest

The ordered data is: 26, 31, 35, 37, 42, 43, 44, 45, 47, 48, 70

Step 2. Find the median of the data

There are 11 values in the dataset. Since n is odd, the median is the observation in the middle.

The middle value is in position (11+1)/2 = 6th position. The value in the sixth positionof the ordered data is 43. Hence, median, Q2 = 43.

In other words, the second quartile, Q2 = 43.

Step 3. Split the data into two halves at Q2

Since the number of observations is odd, we split at the median and exclude Q2 from both halves.

  • Lower half is: 26, 31, 35, 37, 42
  • Upper half is: 44, 45, 47, 48, 70

Step 4. Find the median of the lower half of the data

The lower half has 5 values. Since 5 is odd, the median is the middle value.

From the lower half data, the middle value is 35.

Hence, the first quartile, Q1 = 35

Step 5. Find the median of the upper half of the data

The upper half also has 5 values. Since 5 is odd, the median is the middle value.

From the upper half data, the middle value is 47.

Hence, the third quartile, Q3 = 47

Step 6. Find the interquartile range

The interquartile range, IQR = Q3-Q1

= 47 – 35

=12

In summary:

  • First Quartile (Q1) = 35
  • Second Quartile (Q2 / Median) = 43
  • Third Quartile (Q3) = 47
  • Interquartile Range (IQR) = 12

Alternatively, if you use the quartile calculator, you’ll get similar results, as shown below.

Example 1- calculating quartiles using the calculator when n is odd

Example 2. When n is even

Find the first, second, third, and interquartile range of the following dataset.

Data: 12, 7, 9, 15, 20, 18, 10, 14, 8, 16

Step 1. Arrange the Dataset from Smallest to Largest

The ordered data is: 7, 8, 9, 10, 12, 14, 15, 16, 18, 20

There are 10 values in the dataset.

Step 2. Find the Median of the Data (Q2)

Since n = 10 is even, the median is the average of the two middle values.

Middle positions: 10/2 = 5th and 6th values

  • 5th value = 12
  • 6th value = 14

Thus, median, Q2 = (12 +14)/2

= 13

Hence, the second quartile, Q2 = 13.

Step 3. Split the Dataset Into Two Halves at Q2

Since the number of observations is even, we split the dataset into two equal halves.

  • Lower half: 7, 8, 9, 10, 12
  • Upper half: 14, 15, 16, 18, 20

Note. No observation is excluded in this case.

Step 4. Find the Median of the Lower Half (Q1)

The lower half has 5 values. Since 5 is odd, the median is the middle value.

Middle value = 9

Hence, the first quartile, Q1 = 9.

Step 5. Find the Median of the Upper Half (Q3)

The upper half has 5 values. Since 5 is odd, the median is the middle value.

Middle value = 16

Hence, the third quartile, Q3 = 16.

Step 6. Find the Interquartile Range (IQR)

The interquartile range, IQR = Q3 – Q1

= 16 – 9

= 7

In summary:

  • First Quartile (Q1) = 9
  • Second Quartile (Q2 / Median) = 13
  • Third Quartile (Q3) = 16
  • Interquartile Range (IQR) = 7

Our free quartile calculator also yields similar results, as shown below. Simply copy-paste the data and click the “calculate” button to get similar outputs.

Example 2- Finding Quartiles and IQR using the calculator n is even

Frequently Asked Questions

What are quartiles in statistics?

Quartiles are values that divide a dataset into four equal parts. They include the first quartile (Q1), second quartile (Q2 or median), and third quartile (Q3).

How do you calculate Q1, Q2, and Q3?

To calculate the quartiles (Q1, Q2 and Q3), follow these steps:
– Step 1: Order the dataset from smallest to largest.
– Step 2: Find the median (Q2).
– Step 3: Split the data into lower and upper halves.
– Step 4: Find the median of the lower half to get Q1.
– Step 5: Find the median of the upper half to get Q3.

What is the interquartile range (IQR)?

The interquartile range (IQR) measures the spread of the middle 50% of the data. Its formula is IQR=Q3−Q1

Can quartiles help identify outliers?

Yes. You can use the quartiles and interquartile range to identify outliers. You simply need to calculate:
– Lower bound = Q1 − 1.5 × IQR
– Upper bound = Q3 + 1.5 × IQR
Any data points outside these bounds are considered potential outliers.

Cite this Calculator
Cite:
Embed: