Linear Regression - Exploratory Data Analysis
Sat Nov 19 2022 21:37:34 GMT+0000 (Coordinated Universal Time)
Saved by
@janduplessis883
df.describe()
# Combination of subplot and histogram
plt.figure(figsize=(15,11))
for (i, col) in enumerate(sellers.describe().columns):#["wait_time", "delay_to_carrier", "avg_review_score", "n_orders", "quantity", "price"]):
plt.subplot(3,4,i+1)
sns.histplot(sellers[col], kde=False, stat='density', discrete=[True,None][col in ['share_of_one_stars','share_of_five_stars','sales']]);
#seaborn PairPlot
sns.pairplot(df)
#plotly Scatter Plot
import plotly.express as px
fig = px.scatter(data_frame = sellers[sellers['review_score'] < 4],
x="wait_time",
y="delay_to_carrier",
size="sales",
color="review_score",
size_max = 60,
opacity = 0.5
)
fig.show()
content_copyCOPY
Comments