Back

Explore Courses Blog Tutorials Interview Questions
0 votes
3 views
in Data Science by (17.6k points)

After some operations I have a series that i got after grouping by phone number and counting different calls. I need to count the phone numbers that have an equal number of calls. I mean, if there is 5 people who made 3 calls I need to get a series or a dataframe looking like:

num_calls 

3    5

1    100

...

My series now looks like

phone_num 

89248089190  5

48048102481  6 

12948148014  2

14091404108  5

1 Answer

0 votes
by (36.8k points)

To get the desired output you can use the code below:

.value_counts() does that thing

Improve your knowledge in data science from scratch using Data science online courses 

Related questions

0 votes
1 answer
0 votes
1 answer
asked Jul 31, 2019 in Data Science by sourav (17.6k points)
0 votes
1 answer
0 votes
1 answer

Browse Categories

...