0% found this document useful (0 votes)
47 views22 pages

Assignment Day 8 Subhash Chaudhary

The document provides a comprehensive analysis of Zomato sales data, detailing total revenue, average revenue per transaction, and contribution margins. It identifies Tandoori Chicken as the highest gross profit product and highlights the North region as having the highest ROI and sales volume. Additionally, it explores various predictive models and simulations to assess the impact of pricing changes and new product launches on revenue and profitability.

Uploaded by

Ram
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
47 views22 pages

Assignment Day 8 Subhash Chaudhary

The document provides a comprehensive analysis of Zomato sales data, detailing total revenue, average revenue per transaction, and contribution margins. It identifies Tandoori Chicken as the highest gross profit product and highlights the North region as having the highest ROI and sales volume. Additionally, it explores various predictive models and simulations to assess the impact of pricing changes and new product launches on revenue and profitability.

Uploaded by

Ram
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

✅ 1.

Total revenue, average revenue per transaction, and standard


deviation of revenue
To answer this, I'll now examine the Excel data (Zomato_Sales_Data_India.xlsx.xlsx) and compute the
following:
• Total Revenue = sum of Total_Price
• Average Revenue per Transaction = average of Total_Price
• Standard Deviation of Revenue = standard deviation of Total_Price
Let me process the data and give you the results.
Here are the results based on the Zomato sales data:
• Total Revenue: ₹217,573.90
• Average Revenue per Transaction: ₹884.45
• Standard Deviation of Revenue: ₹557.76

✅ 2. What is the contribution margin if you assume a fixed


COGS (e.g., 60% of unit price)?
We'll calculate:
• COGS = 60% of Unit Price
• Gross Profit per Unit = Unit Price - COGS
• Contribution Margin (%) = (Gross Profit per Unit / Unit Price) × 100
Then, we’ll compute the overall contribution margin across all transactions.
Let’s process this.
The average contribution margin, assuming a fixed COGS of 60% of the unit price, is:

🟢 40.00%

✅ 3. Which product category has the highest gross profit overall?


To do this, we'll:
1. Calculate gross profit per transaction = Total Price × 40% (since contribution margin = 40%)
2. Group by product category (Food Item) and sum gross profit
3. Identify the category with the highest total gross profit
Let’s compute it.
The product category with the highest gross profit overall is:

🍗 Tandoori Chicken
Total Gross Profit: ₹9,758.86
✅ 4. Calculate ROI by category or region, assuming marketing spend
varies by state.
We’ll do the following:
1. Calculate Gross Profit per state and product category (already have gross profit = 40% of total price).
2. Assume or simulate a marketing spend per state (since actual spend is not in the data).
3. Calculate:
ROI=Gross Profit−Marketing SpendMarketing Spend×100\text{ROI} = \frac{\text{Gross Profit} -
\text{Marketing Spend}}{\text{Marketing Spend}} \times 100

Let’s assume a flat marketing spend of ₹2,000 per state for simplicity and compute ROI by state. Let me
calculate that.
Here is the ROI by region, assuming a flat ₹2,000 marketing spend per state:
Region ROI (%)

North 827.44%

West 643.19%

Central 621.49%

Northeast 570.98%

South 556.50%

East 531.89%

North region yields the highest ROI.


Perfect — now let’s solve:
✅ 5. What percentage of total sales is contributed by the top 20% of
transactions (Pareto Principle)?
Approach:
1. Rank all transactions by Total Price in descending order.
2. Take the top 20% of those transactions.
3. Calculate what percentage of total revenue these top transactions contribute.
Let’s compute it.
According to the Pareto Principle analysis:

🟢 The top 20% of transactions contribute 40.25% of total revenue.

✅ 6. What is the Average Order Value (AOV) by product category and


state?
Definition:
AOV=Total RevenueNumber of Transactions\text{AOV} = \frac{\text{Total Revenue}}{\text{Number of
Transactions}}

We’ll compute AOV for each combination of:


• Product Category (Food Item)
• State/Region
Let’s compute it.
Here are the top 10 product category and region combinations by Average Order Value (AOV):
Region Food Item AOV (₹)
West Chowmein ₹2,179.60
Northeast Tandoori Chicken ₹1,767.36
North Thali ₹1,720.00
Northeast Burger ₹1,652.62
Central Pizza ₹1,639.10
Central Thali ₹1,470.62
Northeast Pizza ₹1,441.00
South Momos ₹1,429.34
Central Momos ₹1,352.26
North Fried Rice ₹1,340.89
✅ 7. What are the trends in quantity sold versus revenue per region?
We’ll:
1. Group data by Region
2. Calculate:
o Total Quantity Sold
o Total Revenue
3. Compare regions to see if higher quantity also implies higher revenue.
Let’s compute it.
Here are the trends by region:
Region Quantity Sold Total Revenue (₹)
North 151 ₹46,371.87
West 135 ₹37,159.43
Central 126 ₹36,074.29
Northeast 115 ₹33,549.12
South 105 ₹32,824.80
East 100 ₹31,594.39
Insight: North region leads both in quantity and revenue, showing a strong sales trend. Other regions
follow a similar pattern, though West slightly outperforms Central in revenue with fewer units sold — possibly
due to higher average prices.

✅ 8. Calculate the CAGR (Compound Annual Growth Rate) if data spans


multiple years.
Steps:
1. Extract the year from the Order Date
2. Compute total revenue per year
3. Apply the CAGR formula:
CAGR=(Ending ValueBeginning Value)1n−1\text{CAGR} = \left( \frac{\text{Ending
Value}}{\text{Beginning Value}} \right)^{\frac{1}{n}} - 1

where nn is the number of years


Let’s calculate the CAGR based on the available data.
Here is the annual revenue and CAGR:
Year Total Revenue (₹)

2024 ₹89,686.44

2025 ₹127,887.46

📈 CAGR = 42.59%
This indicates strong year-over-year growth in revenue.

✅ 9. What are the most volatile states in terms of monthly revenue?


Approach:
1. Extract month and year from Order Date
2. Group by state and month to get monthly revenue
3. Compute standard deviation of monthly revenue per state
4. Rank states by volatility (higher standard deviation)
Let’s compute it.
Here are the most volatile states by standard deviation of monthly revenue:
Region Std. Dev. of Monthly
Revenue (₹)
North ₹4,594.07
Central ₹3,338.48
East ₹2,864.36
West ₹2,489.35
South ₹1,698.58
Northeast ₹1,394.64
North is the most volatile in terms of revenue fluctuations month-to-month.
✅ 10. Track customer profitability if you group sales by customer (if customer
data exists)
Let’s check whether the dataset contains any customer identifiers such as:
• Customer ID
• Customer Name
• Email or anything equivalent
If not, we’ll note that this analysis cannot be completed directly.
Let me inspect the column names.
The dataset does not contain any customer identifiers (like Customer ID, Name, or Email).
Therefore, we cannot calculate customer-level profitability with the current data.

✅ 11. Can you build a linear regression model to predict Total_Price?


What features are most predictive?
We’ll:
1. Use features like:
o Unit Price (INR)
o Quantity
o Region (one-hot encoded)
o Food Item (one-hot encoded)
2. Train a Linear Regression model
3. Evaluate the model performance (R²)
4. Identify the most predictive features (coefficients)
Let’s build and analyze the model.

🧠 Linear Regression Results


• R² Score: 0.92
→ The model explains 92% of the variance in Total_Price — a strong predictive performance.

🔍 Top 10 Most Predictive Features:


Feature Coefficient (impact on Total Price)
Quantity +299.14
Food Item: Momos +85.28
Food Item: Chowmein +77.47
Food Item: Tandoori Chicken +69.05
Region: South +64.70
Food Item: Thali +60.10
Food Item: Sandwich −53.63
Food Item: Burger +53.42
Food Item: Rolls +52.65
Food Item: Dosa −29.36
Quantity is by far the most important factor, followed by high-priced food items and certain regions.

✅ 12. Using K-means clustering, which states have similar buying


patterns?
Approach:
1. Group data by Region (state-level)
2. Aggregate:
o Total Revenue
o Total Quantity
o Average Unit Price
3. Standardize features
4. Apply K-Means clustering
5. Analyze which states are in the same clusters
Let’s compute and visualize which states behave similarly.

🤖 K-Means Clustering of States (Regions)


The states were grouped into 3 clusters based on total revenue, quantity sold, and average unit price:
Cluster Regions Description
0 East, Northeast, South Mid-volume, moderate-revenue performers
1 North High revenue and quantity cluster (top)
2 Central, West Balanced performers, slightly higher priced
Insight:
• North stands alone in Cluster 1 — it dominates in both quantity and revenue.
• East, Northeast, and South are similar — possibly good for bundled campaigns.
• Central and West have stable but moderate performance — could be optimized further.

✅ 13. Forecast next quarter’s revenue using past data. What model
performs best: ARIMA, Prophet, or Regression?
Approach:
1. Aggregate monthly revenue
2. Create a time series
3. Fit & compare:
o ARIMA (traditional time series)
o Linear Regression (with time features)
o (Prophet is excluded here as it's not supported in this environment, but noted for future)
We'll evaluate models using:
• Mean Absolute Error (MAE)
• R² Score
Let’s build the time series models and compare performance.

📊 Forecast Model Comparison (Next Quarter Revenue)


Model MAE (₹) R² Score
ARIMA ₹7,873.22 -7.63
Linear Regression ₹18,328.15 -0.64
ARIMA performs better than Linear Regression, despite both models having negative R² values —
indicating limited predictive power due to a small or noisy time series.
Note: The dataset spans only 2 years, so more data would improve forecast accuracy. Prophet, if
supported, might outperform both on richer datasets.

✅ 14. Can you detect any anomalies in the transactions using statistical
thresholds or Isolation Forest?
We’ll detect unusual transactions by:
1. Using the Isolation Forest algorithm on:
o Total Price (INR)
o Unit Price (INR)
o Quantity
2. Flagging anomalies (outliers) in the data.
Let’s run the Isolation Forest and identify the top anomalies.
🚨 Top 5 Anomalous Transactions Detected (Using Isolation Forest):
Date Region Food Item Qty Unit Price (₹) Total Price (₹)
2025-02-09 Central Thali 5 ₹478.30 ₹2,391.50
2024-12-02 North Tandoori Chicken 5 ₹472.95 ₹2,364.75
2024-10-30 East Dosa 4 ₹475.91 ₹1,903.64
2025-01-10 Northeast Tandoori Chicken 4 ₹441.84 ₹1,767.36
2024-12-01 East Rolls 3 ₹491.88 ₹1,475.64
These transactions have unusually high unit prices and total values, and may warrant review for pricing errors
or exceptional orders.

✅ 15. What features (price, category, state) most affect sales volume?
We'll use a Decision Tree Regressor to model:
• Target: Quantity (sales volume)
• Features:
o Unit Price (INR)
o Region
o Food Item
This will help us understand which variables most strongly influence how many units are sold.
Let’s build the model and extract feature importances.

🌟 Feature Importance for Predicting Sales Volume (Quantity Sold)


Feature Importance Score
Unit Price (INR) 0.561
Food Item: Dosa 0.052
Food Item: Chowmein 0.049
Food Item: Sandwich 0.041
Food Item: Tandoori Chicken 0.038
Region: East 0.037
Food Item: Thali 0.034
Food Item: Momos 0.033
Food Item: Pizza 0.026
Region: Northeast 0.021
Unit Price is by far the most influential factor in predicting how many units are sold — indicating clear
price sensitivity.

✅ 16. If unit prices increase by 10%, how does this impact overall revenue
and quantity sold (assuming elasticity)?
Let’s simulate a 10% price increase and assess the impact assuming price elasticity.
Assumptions:
• Price Elasticity of Demand (E) = −1.2 (standard assumption; demand decreases 1.2% for every 1%
increase in price)
• Formula:
% change in quantity=E×% change in price\% \text{ change in quantity} = E \times \% \text{ change
in price}

→ −1.2 × 10% = −12% quantity decrease


We'll:
1. Increase all prices by 10%
2. Reduce quantities by 12%
3. Recalculate total revenue with new values
Let’s simulate this.

📊 Price Sensitivity Simulation (10% Price Increase, Elasticity = −1.2)


Metric Value (₹)
Original Revenue ₹217,573.90
Adjusted Revenue ₹210,611.54
Revenue Change −3.20%
Insight:
Increasing prices by 10% leads to a 12% drop in quantity sold, resulting in a 3.2% decline in overall
revenue.

✅ 17. What happens to revenue if a 5% discount is applied to


Smartwatches in high-performing states?
Note: Your dataset doesn't include "Smartwatches."
We'll substitute it with the most profitable product — which we previously identified as Tandoori Chicken.

Approach:
1. Identify high-performing states (e.g., Top 2 by total revenue: North and West)
2. Apply a 5% discount to Tandoori Chicken in these states
3. Recalculate revenue from those transactions
4. Compare before vs. after discount
Let’s simulate the impact.

🧾 Discount Simulation (5% Off on Tandoori Chicken in Top States)


Metric Value (₹)

Original Revenue ₹217,573.90

Adjusted Revenue ₹216,791.67

Revenue Change −0.36%

Insight:
Offering a 5% discount on Tandoori Chicken in North and West regions reduces total revenue by just
0.36% — a small trade-off that could boost customer acquisition or retention.

✅ 18. Simulate profit impact of launching a new high-margin product in


underperforming states
Assumptions:
• Underperforming states = Bottom 2 by total revenue: East and South
• New product details:
o Unit Price: ₹400
o COGS: ₹120 → Gross Margin: ₹280 per unit (70%)
o Estimated Sales Volume: 50 units per state

Steps:
1. Calculate profit = (Unit Price − COGS) × Quantity
2. Apply to both underperforming states
3. Show projected profit impact
Let’s simulate this.

💼 Profit Simulation: New High-Margin Product Launch


• Target States: East, South (lowest revenue performers)
• Unit Price: ₹400
• COGS: ₹120
• Gross Margin: ₹280
• Estimated Sales: 50 units/state × 2 = 100 units

📈 Projected Additional Profit:


₹28,000
This strategy introduces significant margin leverage in low-performing regions — a strong case for targeted
product expansion.

✅ 19. Which three states would you target for a new marketing campaign
based on sales performance and margin?
We’ll choose states that:
• Have moderate sales (opportunity for growth)
• Generate good margins (profitability potential)

Steps:
1. Use total gross profit (we previously calculated as 40% of revenue)
2. Combine with total revenue
3. Select mid-performing states by revenue but high in margin efficiency
Let’s analyze and pick the top 3 target states.

🎯 Recommended States for Marketing Campaign


Region Revenue (₹) Gross Margin (%)
East ₹31,594.39 40.0%
South ₹32,824.80 40.0%
Northeast ₹33,549.12 40.0%
These states:
• Show moderate sales → room to grow
• Have a strong 40% margin → good profitability potential
Recommendation: Launch a focused marketing campaign in these 3 regions to boost both volume and
margin.

✅ 20. Assume inflation increases COGS by 8%. How does this affect gross
margin across product categories?
Steps:
1. Original COGS = 60% of Unit Price
2. New COGS = COGS × 1.08 (inflation adjusted)
3. Recalculate Gross Profit and Gross Margin % per category
4. Compare old vs. new margins
Let’s compute the impact across all food categories.

📉 Impact of 8% Inflation on COGS — Gross Margin by Category


Food Item Original Margin (%) New Margin (%) Change (%)

All categories 40.0% 35.2% −4.8%

Insight:
Inflation causes a uniform 4.8% drop in gross margin across all product categories — due to proportional
increase in cost for all.
Businesses relying on fixed markup strategies may need to adjust prices or optimize costs to preserve
margin.
You've now completed all 20 scenario-based and strategic financial analysis questions!

🧮 Financial Ratios & Metrics

✅ 21. Calculate GMROI (Gross Margin Return on Investment)


Formula:
GMROI=Gross ProfitAverage Inventory Cost\text{GMROI} = \frac{\text{Gross Profit}}{\text{Average
Inventory Cost}}

Since we don’t have actual inventory data, we’ll simulate Average Inventory Cost as:
• 50% of COGS per category, assuming regular replenishment
We’ll compute GMROI for each Food Item category.
Let’s do the calculation.

📊 GMROI (Gross Margin Return on Investment) — by Product Category


Food Item GMROI

Burger 1.33

Chowmein 1.33

Dosa 1.33

Fried Rice 1.33

Pasta 1.33

Rolls 1.33

Sandwich 1.33

Tandoori Chicken 1.33

Biryani 1.33
Momos 1.33

Insight: All products show a GMROI of 1.33, meaning for every ₹1 invested in inventory, ₹1.33 in gross
profit is returned.

✅ 22. Compute Break-Even Quantity for each category assuming fixed


and variable costs
Formula:
Break-Even Quantity=Fixed CostsUnit Price−Variable Cost (COGS)\text{Break-Even Quantity} =
\frac{\text{Fixed Costs}}{\text{Unit Price} - \text{Variable Cost (COGS)}}

Assumptions:
• Fixed Cost per Category: ₹5,000 (e.g., marketing, admin, overhead)
• Variable Cost: 60% of Unit Price (same as COGS)
We’ll calculate break-even units for each Food Item.
Let’s compute it.

📉 Break-Even Quantity by Product Category


Food Item Avg Unit Price (₹) Break-Even Quantity (units)
Rolls ₹330.29 ~38 units
Dosa ₹317.26 ~39 units
Pasta ₹315.09 ~40 units
Tandoori Chicken ₹304.92 ~41 units
Sandwich ₹304.89 ~41 units
Thali ₹296.16 ~42 units
Pizza ₹293.99 ~43 units
Chowmein ₹291.91 ~43 units
Burger ₹289.37 ~43 units
Fried Rice ₹281.86 ~44 units
Insight: Products with higher prices (e.g., Rolls, Dosa) break even faster.
✅ 23. Estimate NPV and IRR for a new product launch assuming projected
sales and costs over 3 years
Assumptions:
• Initial Investment (Year 0): ₹15,000
• Yearly Net Cash Flows:
o Year 1: ₹7,000
o Year 2: ₹8,000
o Year 3: ₹9,000
• Discount Rate: 10%
We’ll calculate:
• NPV (Net Present Value)
• IRR (Internal Rate of Return)
Let’s compute both.

💰 NPV & IRR for New Product Launch (3-Year Plan)


Metric Value

NPV ₹4,737.04

IRR 26.41%

Insight:
• The project is financially viable: NPV is positive and IRR (26.4%) is well above the 10% discount rate.
• Strong candidate for investment.

✅ 24. Run a sensitivity analysis: How do changes in unit price or quantity


affect revenue?
We’ll simulate the effect of:
• ±10%, ±20% changes in:
o Unit Price
o Quantity
And observe the resulting change in Total Revenue.
Let’s compute this.
📊 Sensitivity Analysis: Revenue Change Based on Price & Quantity Adjustments
Price Change (%) Quantity Change (%) Revenue Change (%)

+20% +20% +44.0%

+20% +10% +32.0%

+10% +20% +32.0%

+10% +10% +21.0%

+20% 0% +20.0%

0% +20% +20.0%

+10% 0% +10.0%

0% +10% +10.0%

+20% −10% +8.0%

−10% +20% +8.0%

Insight:
• Revenue is most sensitive when both price and quantity rise together
• Even with a 10–20% change, effects are quite significant
Would you like to proceed to the final question in this section:
"Calculate EBITDA assuming marketing, logistics, and admin costs as fixed percentages of revenue"?

✅ 25. Calculate EBITDA (Earnings Before Interest, Taxes, Depreciation,


and Amortization)
We'll assume:
• Marketing Cost = 10% of Revenue
• Logistics Cost = 8% of Revenue
• Admin Cost = 5% of Revenue
• COGS = 60% of Unit Price

EBITDA Formula:
EBITDA=Revenue−COGS−Marketing−Logistics−Admin\text{EBITDA} = \text{Revenue} - \text{COGS} -
\text{Marketing} - \text{Logistics} - \text{Admin}
Let’s calculate total EBITDA from the dataset.

📘 EBITDA Summary
Metric Value (₹)
Total Revenue ₹217,573.90
EBITDA ₹36,987.56

Insight: After accounting for COGS and fixed operating costs (marketing, logistics, admin), the business
earns nearly ₹37K in operating profit.

That completes the Financial Ratios & Metrics section!


Would you like to:
• Continue with the Dashboard Questions?
• Explore AI-driven recommendations or customer simulations?
• Or export a summary/report of the insights so far?
• Excellent — moving on to:

✅ 26. What are the total sales per region and per state?
(Note: In this dataset, Region refers to Indian states or macro-zones like North, South, etc.)
Let’s compute total revenue grouped by each region.

🗺️ Total Sales by Region


Region Total Sales (₹)
North ₹46,371.87

West ₹37,159.43
Central ₹36,074.29

Northeast ₹33,549.12

South ₹32,824.80

East ₹31,594.39

North is the top-performing region in terms of total revenue.


Would you like to continue with:
“Which state generates the highest revenue?” (quick follow-up),
or jump directly to category trends or dashboard visual layout?
Great — let’s continue with:

✅ 27. Which state (region) generates the highest revenue?


We’ve already computed this in the last step:
Top Region by Revenue North

Total Revenue ₹46,371.87

No other region outperformed the North, making it the most strategic focus area for campaigns, expansion, or
pilot programs.
Would you like to continue with:
• 28. “Trend of total revenue across different product categories”, or
• Jump to a specific dashboard section (e.g., product analytics, profitability, or AI-driven insights)?

✅ 28. What is the trend of total revenue across different product


categories?
We’ll:
• Group sales by Food Item
• Sum total revenue
• Sort to identify high-performing categories
Let’s analyze it.

📈 Revenue by Product Category


Product Category Total Revenue (₹)
Tandoori Chicken ₹24,397.16
Dosa ₹21,379.40
Sandwich ₹20,945.02
Biryani ₹20,804.37
Pasta ₹19,424.09
Rolls ₹18,943.78
Fried Rice ₹18,411.86
Chowmein ₹18,259.49
Burger ₹17,112.82
Momos ₹14,224.37
Thali ₹12,202.41
Pizza ₹11,469.13
Tandoori Chicken is the top-selling category, followed closely by Dosa and Sandwich — strong
contenders for product promotions.
Would you like to continue with the next dashboard question:
“Which 5 states have the lowest sales performance?”
Great — now for:

✅ 29. Which 5 states have the lowest sales performance?


Since we already have revenue by region, we’ll extract the bottom 5.
Let’s show the lowest-performing states.

🚩 Bottom 5 States (Regions) by Sales Performance


Rank Region Total Sales (₹)

1 East ₹31,594.39

2 South ₹32,824.80

3 Northeast ₹33,549.12

4 Central ₹36,074.29

5 West ₹37,159.43

These regions have lower revenue and could be:


• Targets for marketing to boost performance
• Candidates for new product or discounting strategies
Would you like to continue to:
• Product analytics dashboard questions, or
• Another section like AI-driven insights or customer behavior simulations?

✅ 30. What are the top 5 best-selling product categories by revenue and
quantity?
We’ll compute:
1. Top 5 by Revenue
2. Top 5 by Quantity Sold
Let’s calculate both.

🔝 Top 5 Best-Selling Product Categories


💰 By Revenue:
Rank Food Item Revenue (₹)
1 Tandoori Chicken ₹24,397.16
2 Dosa ₹21,379.40
3 Sandwich ₹20,945.02
4 Biryani ₹20,804.37
5 Pasta ₹19,424.09
📦 By Quantity Sold:
Rank Food Item Quantity Sold

1 Biryani 79

2 Tandoori Chicken 78

3 Sandwich 73

4 Dosa 72

5 Fried Rice 64

Biryani, Tandoori Chicken, and Sandwich appear in both lists — high-volume and high-revenue drivers.

You might also like