Anushree2000 commited on
Commit
fbb62ea
·
verified ·
1 Parent(s): 176a71f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +0 -37
app.py CHANGED
@@ -49,43 +49,6 @@ ecommerce_data = pd.DataFrame({
49
  ecommerce_data.head()
50
 
51
 
52
- import matplotlib.pyplot as plt
53
- import seaborn as sns
54
-
55
- # Set Seaborn style
56
- sns.set_style("whitegrid")
57
-
58
- # Create subplots
59
- fig, axes = plt.subplots(2, 2, figsize=(14, 10))
60
-
61
- # 1. Price Distribution Across Categories
62
- sns.boxplot(x="Category", y="Base_Price", data=ecommerce_data, ax=axes[0, 0], palette="Set2")
63
- axes[0, 0].set_title("Price Distribution Across Categories")
64
- axes[0, 0].set_xlabel("Category")
65
- axes[0, 0].set_ylabel("Base Price")
66
- axes[0, 0].tick_params(axis='x', rotation=30)
67
-
68
- # 2. Competitor Price vs. Base Price
69
- sns.scatterplot(x="Base_Price", y="Competitor_Price", data=ecommerce_data, ax=axes[0, 1], color="blue", alpha=0.7)
70
- axes[0, 1].set_title("Competitor Price vs. Base Price")
71
- axes[0, 1].set_xlabel("Base Price")
72
- axes[0, 1].set_ylabel("Competitor Price")
73
-
74
- # 3. Seasonality Impact on Demand
75
- sns.scatterplot(x="Seasonality_Factor", y="Demand", data=ecommerce_data, ax=axes[1, 0], color="green", alpha=0.7)
76
- axes[1, 0].set_title("Seasonality Impact on Demand")
77
- axes[1, 0].set_xlabel("Seasonality Factor")
78
- axes[1, 0].set_ylabel("Demand")
79
-
80
- # 4. Price vs. Demand Relationship
81
- sns.scatterplot(x="Base_Price", y="Demand", data=ecommerce_data, ax=axes[1, 1], color="red", alpha=0.7)
82
- axes[1, 1].set_title("Price vs. Demand Relationship")
83
- axes[1, 1].set_xlabel("Base Price")
84
- axes[1, 1].set_ylabel("Demand")
85
-
86
- # Adjust layout and show plot
87
- plt.tight_layout()
88
- plt.show()
89
 
90
 
91
  import streamlit as st
 
49
  ecommerce_data.head()
50
 
51
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
52
 
53
 
54
  import streamlit as st