import pandas as pd
In [86]:
ecom = pd.read_csv('Ecommerce Purchases')
Check the head of the DataFrame.
In [86]:
ecom = pd.read_csv('Ecommerce Purchases')
Check the head of the DataFrame.
In [87]:
ecom.head()
Out[87]:
In [88]:
ecom.info()
In [90]:
ecom['Purchase Price'].mean()
Out[90]:
In [92]:
ecom['Purchase Price'].max()
Out[92]:
In [93]:
ecom['Purchase Price'].min()
Out[93]:
In [94]:
ecom[ecom['Language']=='en'].count()
Out[94]:
In [95]:
ecom[ecom['Job'] == 'Lawyer'].info()
In [96]:
ecom['AM or PM'].value_counts()
Out[96]:
In [97]:
ecom['Job'].value_counts().head(5)
Out[97]:
In [99]:
ecom[ecom['Lot']=='90 WT']['Purchase Price']
Out[99]:
In [100]:
ecom[ecom["Credit Card"] == 4926535242672853]['Email']
Out[100]:
In [101]:
ecom[(ecom['CC Provider']=='American Express') & (ecom['Purchase Price']>95)].count()
Out[101]:
In [102]:
sum(ecom['CC Exp Date'].apply(lambda x: x[3:]) == '25')
Out[102]:
In [56]:
ecom['Email'].apply(lambda x: x.split('@')[1]).value_counts().head(5)
Out[56]:
No comments:
Post a Comment