How to use the TRUNC function in Excel?
There are various ways in Excel to remove decimal and shorten numeric values. In this article, TipsMake.com will explain how to use the TRUNC function and show what makes it different from other techniques.
How to use the TRUNC function?
See examples of the TRUNC function with some sample data. The following example uses the following TRUNC function.
=TRUNC(A2)
If you do not specify how many digits are to be truncated, all decimal places will be removed.

You can see with the value in cell A2 that the TRUNC function does not apply any rounding. It simply cuts to 411.
Let us see another example. This time the example will reduce the values to two decimal places.
=TRUNC(A2,2)

The TRUNC function will not display more decimal numbers if you request it to display more numbers than you have.
Take the following example and cut it down to 2 decimal places.
=TRUNC(A2,2)

The value in cell A4 is reduced to 2 decimal places, but the values in A2 and A3 remain the same because they have fewer than two decimal places.
If you want to display two decimal numbers, the cells will need to be formatted to force them to be displayed.
Clear part of the day and time stamp
A useful example of TRUNC is to remove the time part from the date and the timestamp in Excel.
Imagine you have the following dates and timestamps, but you just want to have the date part in the column for analysis.

The following formula will remove the time portion.
=TRUNC(A2)

Although the time section has been removed, the resulting cells will still need to be formatted as dates.
Use TRUNC to shorten numbers
This is a rare technique. When you use negative numbers, the function cuts the numbers to the left of the decimal point. However, it does not change the number of digits, but replaces them with zeroes.
Take a look at the following example.
=TRUNC(A2,-1)

You can see in each example that the number 0 is used to replace the number removed to the left of the decimal point.
There are many ways in Excel to delete decimal places, however, most of them will round numbers. The strength of the TRUNC function is that it does not round values and simply shortens them to the specified number of decimal places.
You should read it
- How to fix the SUM function doesn't add up in Excel
- Guidance on how to align Excel correctly
- How to keep Excel and Excel columns fixed?
- What is ### error in Excel? how to fix ### error in Excel
- How to display 0 in front of a number in Excel
- Instructions for searching and replacing in Excel tables
- MS Excel 2007 - Lesson 2: Customizing in Excel
- 3 ways down the line in Excel, line break, down row in 1 Excel cell
May be interested
- How to use the IFS function in Excel 2016the ifs function in excel is a logical function introduced in excel 2016. this function is a function that replaces the nested if function and is much easier to use. the ifs function checks one or more conditions and returns a value that meets the first true condition.
- How to use the NPER function in Excel to plan loans and savingsdo you want to effectively manage and control your personal finances? then we invite you to learn how to use excel's nper function.
- How to use the function to delete spaces in Exceldeleting white space with functions in excel makes it easier for users to handle content, instead of traditional editing.
- How to fix the SUM function doesn't add up in Excelin the process of summing with sum in excel, you will encounter some errors such as not jumping the number, not adding the sum. so how to handle this problem?
- How to use the SUBTOTAL function in Excelthe subtotal function in excel is used in many different cases, helping you to sum subtotals in a list or database, unlike the sum function in excel such as counting cells, calculating average, finding the largest / smallest value. or sum the filtered list values in excel
- Save time with these text formatting functions in Microsoft Excelmicrosoft excel is a main application for anyone who has to work with numbers, from students to accountants. but its usefulness extends beyond a large database, it can do a lot of great things with text. the functions listed below will help you analyze, edit, convert, change text and save many hours of boring and repetitive tasks.
- SUMPRODUCT function in Excel: Calculates the sum of corresponding valuesthe sumproduct function is an extremely useful function when you have to deal with a lot of data numbers in microsoft excel. here are the things you need to know about the sumproduct function in excel.
- How to use the SUMIF function in Excelthe sumif function in excel is a function used to compute values in a specified range. the sumif function can be used for summing cells based on the date, data and text that are connected to the specified area.
- How to use the DAVERAGE function in Exceldaverage in excel is a function that calculates the average value of data with given conditions in a spreadsheet. so, how to use this function?
- How to use the kernel function (PRODUCT function) in Excelin excel, product helps users to calculate product values, multiply arguments together, and return their results correctly.