How to return the number of values that has a specific count
I would like to find how many occurrences of a specific value count a column contains. For example, based on the data frame below, I want to find how many values in the ID column are repeated twice
| ID |
| -------- |
| 000001 |
| 000001 |
| 000002 |
| 000002 |
| 000002 |
| 000003 |
| 000003 |
The output should look something like this
Number of ID's repeated twice: 2
The ID's that are repeated twice are:
| ID |
| -------- |
| 000001 |
| 000003 |
Any help would be appreciated.
Topic data-analysis pandas python
Category Data Science