<jupyter_start><jupyter_text><jupyter_code>import pandas as pd
import numpy as np

cust_rating = pd.read_csv('https://query.data.world/s/ILc-P4llUraMaYN6N6Bdw7p6kUvHnj')

#cust_rating['avg_rating'] = round(#Type your code here.)

print(cust_rating.head(3))
url = 'https://raw.githubusercontent.com/Srinunosina/FDS/master/odi-batting.csv?token=<KEY>'
df = pd.read_csv(url, sep='\t', encoding="ISO-8859-1")

df = pd.read_csv(url)
print(df.head(5))
url = 'https://raw.githubusercontent.com/Srinunosina/FDS/master/odi-batting.csv?token=<KEY>'
pd.set_option('display.max_columns', None)
df_test = pd.read_csv(url)
print(df_test.head(5))
df_test1['scored_century'] = df_test1['Runs'].apply(lambda x: 1 if x >=100 else 0)
df_test_cen['strike_rate'] = (df_test_cen['Runs']/df_test_cen['Balls'])*100
df_test_cen.head(2)
#df_test_cen = df_test[df_test.scored_century == 1]
#df_test_cen.sort_values(by='strike_rate', ascending=False)
#top9 = master_frame[master_frame['funding_round_type']=='venture'].groupby('country_code').sum().sort_values('raised_amount_usd', ascending=False).head(9)
df_test_cen = df_test[df_test.scored_century == 1].groupby('Player').sum().sort_values('strike_rate', ascending=False)
df_test_cen.head(5)

# D1[D1['main_sector']=='Others'].groupby(['main_sector','permalink']).raised_amount_usd.sum().sort_values(ascending=False).head()
df_test_cen1 = df_test[df_test.scored_century == 1].groupby(['Player','strike_rate']).sum().sort_values('strike_rate', ascending=False)
df_test_cen1.head(5)

# In which year were the maximum number of centuries scored by Indian players?
#df_test.head(4)
df_test['Year'] =  df_test['MatchDate'].apply(lambda x: x.split('-')[2])
df_test_con = df_test[df_test.Country == 'India']
df_test_con.head(4)
df_year = df_test_con[df_test_con.scored_century == 1].groupby('Year').sum().sort_values('scored_century', ascending=False)
df_year<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.17819706498951782, 'fraction_numerical': 0.020440251572327043, 'mean_word_length': 8.84020618556701, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 8, 'https://': 3, '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': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '90033', 'license': 'Apache-2.0', 'n_tokens_mistral': 786, 'n_tokens_neox': 756, 'n_words': 90, 'path': 'Ondi_Cricter_PracticeQuestion.ipynb', 'repo_name': 'Srinunosina/npoi', 'size': '1956'}