<jupyter_start><jupyter_text>Basic Analysis Solution<jupyter_code>import pandas as pd
oo = pd.read_csv('data/olympics.csv',skiprows=4)
oo.head()<jupyter_output><empty_output><jupyter_text>In which events did <NAME> win a medal?<jupyter_code>jo = oo[oo.Athlete == 'OWENS, Jesse']
jo
jo.Event.value_counts()<jupyter_output><empty_output><jupyter_text>Which country has won the most men's gold medals in singles badminton over the years? Sort the results alphabetically by the player's  names.<jupyter_code>gbm = oo[(oo.Medal == 'Gold') & (oo.Gender == 'Men') & (oo.Sport == 'Badminton')]
gbm.sort_values(by='Athlete')<jupyter_output><empty_output><jupyter_text>Which three countries have won the most medals in recent years (from 1984 to 2008)?<jupyter_code>rec = oo[oo.Edition >= 1984]
rec.NOC.value_counts().head(3)<jupyter_output><empty_output><jupyter_text>Display the male gold medal winners for the 100m Track & Field sprint event over the years. List the results starting with the most recent. Show the Olympic City, Edition, Athlete and the country they represent.<jupyter_code>gmh = oo[(oo.Gender == 'Men') & (oo.Medal == 'Gold') & (oo.Event == '100m')]
gmh.sort_values('Edition',ascending=False)[['City','Edition','Athlete','NOC']]
oo.Event.value_counts()<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.139984532095901, 'fraction_numerical': 0.015467904098994586, 'mean_word_length': 7.457516339869281, 'pattern_counts': {'":': 0, '<': 22, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '5', 'dir': 'jupyter-structured-clean-dedup', 'id': '209751', 'license': 'MIT', 'n_tokens_mistral': 487, 'n_tokens_neox': 453, 'n_words': 109, 'path': '2/olympics-analysis/4.ipynb', 'repo_name': 'abphilip-resources/DO-Docker-1', 'size': '1298'}