Pandas Stats Exercises—Baby Names

preview_player
Показать описание
Sometimes we learn best by doing. Unlike my other videos, I’ll be going through these exercises cold. Sometimes we’ll encounter ambiguous questions, and sometimes I'll be wrong. Learning from our mistakes can be a powerful teacher. So, it’s OK to be wrong now, because we’ll know how to avoid it next time when it counts. My hope is that you will learn by doing.

Why don’t you proceed through the linked exercises before we walk through them together?

This series can be viewed in tandem with my “An Opinionated Guide to pandas” video series (links below), but it’s not required. This series is beginner-friendly but aimed most directly at intermediate users.

This Learning by Doing is part of the pandas Opinionated Guide series:

The jupyter notebooks can be found here:

guipsamora’s exercises can be found here:
Рекомендации по теме
Комментарии
Автор

I discovered your channel while searching for Pandas tutorials; thanks so much for creating these videos!

zixinlee
Автор

step 6 has a logical mistake, the question asked for what is more F or M (names) in the dataset, and we should have evaluated that regarding the names themselves, meanwhile you evaluated regarding their counts, and you found out that males are more.
male babies as a number were more indeed, but female names (as variety) were more.

Thank you for the interesting videos, I like the spirit you put within the video. keep going :).

ahmadKha
Автор

Hello Mr.DataTalks, your pandas series has been absolutely invaluable to me. Cheers, really appreciate the work

formulafacebookfan
Автор

Appreciate the work! Please keep these tutorials coming.

emirhan
Автор

Things I learned from this lecture:
baby_names.groupby(['Gender', 'Name']).agg({'Count':'sum'}).reset_index().sort_values(['Gender', 'Count'], ascending=[0, 0]).set_index(['Gender', 'Name'])

arhataria
Автор

Hi, thank you for your great video. Any chance you could do a video on time series, and how to create graphs from df.groupby and df.pivot_table? Thanks in advance

rhard
Автор

Hi @datatalks, can you attempt for Occupation grouping exercise ?

swarupghadei
Автор

Thanks for the video! Just a note: the excercise about the number of different names of the least occurence was done wrong - you took sum instead of len.

timurdothamzin
Автор

(baby_names['Gender'] == 'F').mean() is an intriguing expression. The value of (baby_names['Gender'] == 'F') is a boolean Series, and since False=0 and True=1 in Python, the mean of the values in the Series is the percentage of the female names in the dataset.

jimmymesa