import pandas as pd
# from google.cloud import bigquery
import seaborn as sns
# client = bigquery.Client.from_service_account_json(r'C:\Users\lmeji\OneDrive\Github\Python\BigQuery\fleet-parser-330316-d0e1b6cf4fd1.json')
log_weighins = pd.read_excel(r'C:\Users\lmeji\OneDrive\Documents\Tableau\Files for Tableau\Luis - Log.xlsx',sheet_name='WeighIns')
%matplotlib inline
try:
sns_df = sns.load_dataset('tips') #this is using a builtin dataset called "tips"BytesWarning
sns.displot(sns_df[['total_bill']], kde=True, bins=30)
except Exception as e:
print(e)
sns.jointplot(x='total_bill',y='tip',data=sns_df,kind='reg') #kind='hex','reg','scatter','kde'
<seaborn.axisgrid.JointGrid at 0x1c5ccf5fe10>
sns.pairplot(sns_df,hue='sex') # palette='pink'
<seaborn.axisgrid.PairGrid at 0x1c5ccf97590>
sns.rugplot(sns_df['total_bill'])
<AxesSubplot: xlabel='total_bill'>
sns.boxplot(x='day',y='total_bill',data=sns_df,hue='smoker')
<AxesSubplot: xlabel='day', ylabel='total_bill'>
print(sns_df.head(10))
sns.countplot(x='sex',data=sns_df,hue='smoker')
total_bill tip sex smoker day time size 0 16.99 1.01 Female No Sun Dinner 2 1 10.34 1.66 Male No Sun Dinner 3 2 21.01 3.50 Male No Sun Dinner 3 3 23.68 3.31 Male No Sun Dinner 2 4 24.59 3.61 Female No Sun Dinner 4 5 25.29 4.71 Male No Sun Dinner 4 6 8.77 2.00 Male No Sun Dinner 2 7 26.88 3.12 Male No Sun Dinner 4 8 15.04 1.96 Male No Sun Dinner 2 9 14.78 3.23 Male No Sun Dinner 2
<AxesSubplot: xlabel='sex', ylabel='count'>
sns.violinplot(x='day',y='total_bill',data=sns_df,hue='sex',split=True)
<AxesSubplot: xlabel='day', ylabel='total_bill'>