Advertisement
ShrekOP

Assg15

Dec 14th, 2022
46
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.56 KB | None | 0 0
  1. import pandas as pd
  2. import numpy as np
  3. import matplotlib.pyplot as plt
  4. import seaborn as sns
  5. df=pd.read_csv("tested.csv")
  6.  
  7. from google.colab import drive
  8. drive.mount('/content/drive')
  9.  
  10. df.head(5)
  11.  
  12. sns.distplot(df['Fare'])
  13.  
  14. x=df['Fare']
  15. plt.hist(x,bins=25,color='green',edgecolor='blue',alpha=0.5)
  16. plt.title('Histogram')
  17. plt.xlabel('Sex')
  18. plt.ylabel('Pclass')
  19.  
  20. sns.jointplot(x='Age',y='Fare',data=df)
  21.  
  22. sns.pairplot(df)
  23.  
  24. sns.barplot(x='Age',y='Sex',data=df)
  25.  
  26. sns.boxplot(x='Age',y='Sex',data=df)
  27.  
  28. sns.violinplot(x='Sex',y='Age',data=df,hue='Sex')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement