View Full Version : Truncating numbers to their leading digit only?


dave @ ptrecs
11-20-2006, 01:10 PM
I'm just getting into the data collection part of a project, and have a lump of 2,600 data values to analyse. It's not difficult, but I need to truncate the numbers, so that they only show the first digit.

i.e. I want the entry '76012' to show '7', '3145' to show '3'. and so on and so forth...

I need to do this so that I can use the COUNTIF formula on the data range to count to number of leading 1s, 2s, 3s, etc. to explore Benford's Law, and it's escaping me so far.

Any help would be excellent!

KeithG
11-20-2006, 01:14 PM
You need to use the Left function.

dave @ ptrecs
11-20-2006, 01:18 PM
You're a star.
Thank you very much.

neileg
11-22-2006, 02:57 AM
Wouldn't it be easier to do a pivot instead of using CountIf?