Seaborn Barplot Method

Machine Learning courses with 100+ Real-time projects Start Now!!

Program 1

Seaborn Dataset

import pandas as pd
import numpy as np
import seaborn as sns

df_tip=pd.read_csv("D://scikit_data/Billing/tips.csv")

df_tip.head()

df_tip.shape

df_tip.info()

df_tip.isnull().sum()

sns.barplot(x='day',y='total_bill',hue='sex',data=df_tip,hue_order=['Male','Female'])

sns.barplot(x='day',y='total_bill',hue='sex',hue_order=['Male','Female'],order=['Thur','Fri','Sat','Sun'],data=df_tip)

sns.barplot(x='day',y='total_bill',hue='sex',data=df_tip)

sns.barplot(x='day',y='total_bill',hue='sex',data=df_tip,ci=12)

sns.barplot(x='day',y='total_bill',hue='sex',data=df_tip,orient='h')

sns.barplot(y='day',x='total_bill',hue='sex',data=df_tip)

sns.barplot(x='size',y='total_bill',hue='sex',data=df_tip,orient='v')

sns.barplot(x='size',y='total_bill',hue='sex',data=df_tip,color='b')

sns.barplot(x='size',y='total_bill',hue='sex',data=df_tip,palette='Accent')

 

 

 

Your 15 seconds will encourage us to work even harder
Please share your happy experience on Google

courses

DataFlair Team

DataFlair Team provides high-impact content on programming, Java, Python, C++, DSA, AI, ML, data Science, Android, Flutter, MERN, Web Development, and technology. We make complex concepts easy to grasp, helping learners of all levels succeed in their tech careers.

Leave a Reply

Your email address will not be published. Required fields are marked *