Data Viz

PHOTO EMBED

Wed Jul 05 2023 00:37:38 GMT+0000 (Coordinated Universal Time)

Saved by @busthon

 # importing the required library
import seaborn as sns
import matplotlib.pyplot as plt
 
# read a titanic.csv file
# from seaborn library
df = sns.load_dataset('titanic')
 
 
# who v/s fare barplot
sns.barplot(x = 'who',
            y = 'fare',
            hue = 'class',
            data = df)
 
# Show the plot
plt.show()
content_copyCOPY