How to Filter and Work with Decimal Numbers in Google Sheets

Published on

Imagine you have a list in Google Sheets containing a mix of decimal and integer numbers. How can you filter only the decimal numbers from this list?

This is Question #1, which I’ll answer in this tutorial. As a bonus, I’ll also tackle Question #2:

How can you filter decimal numbers with specific decimal fractions?

For example, filtering numbers with a fraction of 0.25—but you can easily modify this to suit your needs.

Formula to Filter Decimal Numbers in Google Sheets

To filter decimal numbers, we’ll use the INT function along with either IF or FILTER. Both approaches achieve the same goal but produce slightly different outputs:

  • INT with IF: May leave blank cells in the results where no match is found.
  • INT with FILTER: Returns only the matching values without blank cells.

First, let’s learn how to filter decimal numbers. Then, we’ll cover how to filter numbers with specific decimal fractions. The formulas for both are nearly identical, with the main difference being the comparison operator used.

How to Filter Decimal Numbers in Google Sheets

Here’s the formula to extract decimal numbers:

=ArrayFormula(IF(A2:A-INT(A2:A)<>0, A2:A, ))
  • The range A2:A contains the input data.
  • Use this formula in cell B2.
  • Before applying the formula, ensure the range B2:B is clear of any values or formulas.
Example: Returning Decimal Numbers Using IF and INT in Google Sheets

Alternatively, you can use the FILTER function to achieve the same result:

=FILTER(A2:A, A2:A-INT(A2:A)<>0)
Example of Filtering Decimal Numbers in Google Sheets

Both formulas will do the job, but the FILTER version excludes blank rows.

Additional Tip

If you apply the above formulas to a column containing dates and timestamps, they will return the timestamps. This is because dates in Google Sheets are stored as integers, while times are stored as fractions of a day. Therefore, a timestamp is treated as a decimal number.

Filter Specific Decimal Fractions in Google Sheets

To filter decimal numbers with a specific fraction (e.g., 0.25), modify the formula as follows:

Formula #1 (Using INT with IF):

=ArrayFormula(IF(A2:A-INT(A2:A)=0.25, A2:A, ))

Formula #2 (Using INT with FILTER):

=FILTER(A2:A, A2:A-INT(A2:A)=0.25)

Both formulas will return numbers with the desired fraction (e.g., 0.25). For instance, if the dataset contains 100.25, 300.25, and 0.25, these numbers will appear as output.

Key Takeaways

To filter decimal numbers in Google Sheets, you can combine the INT function with either IF or FILTER. This approach effectively separates decimal numbers from integers in your data.

If you need to filter specific decimal fractions, you can adjust the formula by replacing 0.25 with your desired fraction. This allows for precise filtering tailored to your requirements.

For cleaner outputs without blank cells, the FILTER function is the ideal choice, as it directly excludes non-matching values.

Additional Resources

Prashanth KV
Prashanth KV
Your Trusted Google Sheets and Excel Expert Prashanth KV is a Diamond Product Expert in Google Sheets, officially recognized by Google for his contributions to the Docs Editors Help Community and featured in the Google Product Experts Directory. With years of experience working with Google Sheets and Excel for multinational firms in Mumbai and Dubai, he has been blogging since 2012, offering practical, real-world spreadsheet solutions that professionals rely on. Explore his blog to learn advanced formulas, automation tips, and problem-solving techniques to elevate your spreadsheet skills.

How to Count Merged Cells in Google Sheets (and Get Their Size)

Sometimes, you may have blocks of merged cells in a column or row. But...

Count Consecutive Workday Absences in Google Sheets

This tutorial offers a powerful formula-based solution to count consecutive workday absences in Google...

Top N Products and Top N Sellers in Google Sheets (Top N of Top N)

If you’ve ever wanted to compare which sellers contribute the most to your top-selling...

Use XLOOKUP in a Structured Table in Google Sheets (Single and Multiple Conditions)

This tutorial is for users who want to apply XLOOKUP inside a structured table...

More like this

How to Count Merged Cells in Google Sheets (and Get Their Size)

Sometimes, you may have blocks of merged cells in a column or row. But...

Count Consecutive Workday Absences in Google Sheets

This tutorial offers a powerful formula-based solution to count consecutive workday absences in Google...

Top N Products and Top N Sellers in Google Sheets (Top N of Top N)

If you’ve ever wanted to compare which sellers contribute the most to your top-selling...

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.