How to count the number of occurences of an integer in excel?

  • Thread starter Keshroom
  • Start date
  • #1
25
0

Homework Statement


I have a thousand random numbers generated between -100 and 100 and want to count the number of occurences of each integer. I know i can use the COUNTIF function, but for so many numbers it takes way too long. Is there a way to create a loop in excel that can do this or will i just have to use ranges (eg. occurences between 0 and 10). For the accuracy i want to count each number individually.

Thanks!


Homework Equations





The Attempt at a Solution

 

Answers and Replies

  • #2
gneill
Mentor
20,925
2,867
Two suggestions:
1. Write a macro to do it.
2. Use the FREQUENCY array function to count them into "bins" of unit size (or any size you like for that matter).

For 2 you will probably have to add an offset to all the values (100 in your case) so that all the data values will be positive.
 

Related Threads on How to count the number of occurences of an integer in excel?

Replies
1
Views
3K
Replies
2
Views
484
Replies
9
Views
11K
Replies
3
Views
557
  • Last Post
Replies
0
Views
8K
Replies
1
Views
875
  • Last Post
Replies
2
Views
8K
Top