PDS Guided Project – Python for Data Science
Business Analysis report – Food Hub
- Yeshwanth J P
1
Table of Contents
Who is food Hub 4
Objective 4
Data Dictionary4
Question 1 5
Question 2 5
Question 3 5
Question 4 …………………………………………………………………………………………………………………………………..6
Question 5 ………………………………………………………………………………………………………………………………….6
Exploratory Data Analysis…………………………………………………………………………………………………………….6
Univariate Analysis………………………………………………………………………………………………………………….6
Question 6 ………………………………………………………………………………………………………………………….6
Cost of Order …………………………………………………………………………………………………………………7
Day of the Week …………………………………………………………………………………………………………….8
Rating …………………………………………………………………………………………………………………………….9
Food Preparation Time ………………………………………………………………………………………………….9
Delivery Time ……………………………………………………………………………………………………………….10
Question 7 ………………………………………………………………………………………………………………………….10
Question 8 ………………………………………………………………………………………………………………………….11
Question 9 ………………………………………………………………………………………………………………………….11
Question 10 ……………………………………………………………………………………………………………………….11
Question 11 ……………………………………………………………………………………………………………………….11
Multi-Variate Analysis …………………………………………………………………………………………………………….12
Question 12 ……………………………………………………………………………………………………………………….12
Cuisine vs Cost of the order ………………………………………………………………………………………….12
Cuisine vs Food Preparation time …………………………………………………………………………………13
Day of the Week vs Delivery time ……………………………………………………………………………….13
observations on the revenue generated by the restaurants …………………………………………..14
Rating vs Delivery time ………………………………………………………………………………………………..14
Rating vs Food preparation time …………………………………………………………………………………..14
Rating vs Cost of the order ……………………………………………………………………………………………15
Question 13 ………………………………………………………………………………………………………………………16
Question 14 ………………………………………………………………………………………………………………………16
2
Question 15 ………………………………………………………………………………………………………………………16
Question 16 ………………………………………………………………………………………………………………………17
Actionable Insights and Recommendations …………………………………………………………………………………17
Actionable Insights ………………………………………………………………………………………………………………..17
Recommendations …………………………………………………………………………………………………………………18
3
Who is ‘Food Hub’?
A popular food aggregator platform, Food Hub uses an easy-to-use smartphone app to link clients
with a variety of restaurants. Using a commission-based business model, Food Hub collaborates with
a large number of eateries to provide a wide variety of culinary options. The platform generates
income through a set margin on each order while facilitating online orders, allocating delivery staff,
and guaranteeing on-time delivery.
Objective
To examine past order data in order to spot patterns, client inclinations, and operational waste.
Customer satisfaction, delivery efficiency, and restaurant partnerships will all be improved with this
analysis.
Data Dictionary
order_id: Unique ID of the order
customer_id: ID of the customer who ordered the food
restaurant_name: Name of the restaurant
cuisine_type: Cuisine ordered by the customer
cost_of_the_order: Cost of the order
day_of_the_week: Indicates whether the order is placed on a weekday or weekend (The
weekday is from Monday to Friday and the weekend is Saturday and Sunday)
rating: Rating given by the customer out of 5
food_preparation_time: Time (in minutes) taken by the restaurant to prepare the food. This
is calculated by taking the difference between the timestamps of the restaurant's order
confirmation and the delivery person's pick-up confirmation.
4
delivery_time: Time (in minutes) taken by the delivery person to deliver the food package.
This is calculated by taking the difference between the timestamps of the delivery person's
pick-up confirmation and drop-off information
Question 1: How many rows and columns are present in the data?
There are 1898 rows and 9 columns.
Question 2: What are the datatypes of the different columns in the
dataset?
Data
Column Name Type Description
order_id int64 Unique identifier for each order
customer_id int64 Unique identifier for each customer
restaurant_name object Name of the restaurant
cuisine_type object Type of cuisine ordered
cost_of_the_order float64 Total cost of the order
day_of_the_week object Day of the week the order was placed
rating object Customer rating for the order (out of 5)
Time taken by the restaurant to prepare the
food_preparation_time int64 food (in minutes)
Time taken by the delivery person to deliver
delivery_time int64 the food (in minutes)
Question 3: Are there any missing values in the data? If yes, treat them
using an appropriate method.
No, there are no missing values.
5
Question 4: Check the statistical summary of the data. What is the
minimum, average, and maximum time it takes for food to be prepared once
an order is placed?
Minimum time for the food to be prepared once the order is placed ---> 20 minutes
Average time for the food to be prepared once the order is placed ---> 27.37 minutes
Maximum time for the food to be prepared once the order is placed ---> 35 minutes
Question 5: How many orders are not rated?
There are 736 orders where the Ratings are not given.
Exploratory Data Analysis (EDA)
Univariate Analysis
Question 6: Explore all the variables and provide observations on their
distributions. (Generally, histograms, boxplots, count plots, etc. are used for
univariate exploration.)
There are a total of 1898 unique order id
There are total of 1200 unique customer id's
The are a total of 178 unique restaurants
There a total of 14 unique cuisines
6
from this count plot we can find which are all the most ordered cuisines
1 --> American
2 --> Japanese
3 --> Italian
4 --> Chinese
5 --> Mexican and Indian
Above are the top 5 cuisines order by the customers from various restaurants.
Cost of the order
From both the Histogram and Boxplot we can conclude below things.
7
Cost of the order is rightly skewed
The Highest cost of the order is 350
The lost cost of the order is 5
The median value of the order is 13
There are no outliers
Day of the week
From the count plot we can conclude that the orders on weekend>weekday
8
Rating
From the Count Plot we can clearly see the below conclusion
For 700+ orders there are no rating given
550+ orders got a rating of 5
400 orders got a rating of 4
170+ orders got a rating of 3
There is no rating below 3
Food Preparation time
9
The minimum time taken to prepare the food is 20 minutes
The maximum time taken to prepare the food is 35 Minutes
The Median time is 27 minutes
There are no outliers
Delivery time
The Minimum time taken to deliver is 15 Minutes
The Maximum time taken to deliver is 33 Minutes
The Median time taken to deliver is 33 Minutes
There are no outliers observed
Question 7: Which are the top 5 restaurants in terms of the number of
orders received?
Restaurant Name Order
Shake Shack 219
The Meatball Shop 132
Blue Ribbon Sushi 119
Blue Ribbon Fried
Chicken 96
Parm 68
10
Question 8: Which is the most popular cuisine on weekends?
Top 3 cuisine’s on the weekend are below
cuisine type Orders
American 415
Japanese 335
Italian 207
Question 9: What percentage of the orders cost more than 20 dollars?
The number of total orders that cost above 20 dollars is: 555
Percentage of orders above 20 dollars: 29.24 %
Question 10: What is the mean order delivery time?
The mean delivery time for this dataset is 24.16 minutes
Question 11: The company has decided to give 20% discount vouchers
to the top 3 most frequent customers. Find the IDs of these customers and
the number of orders they placed.
Orders
customer_id
placed
52832 13
47440 10
83287 9
11
Multi-Variate Analysis
Question 12: Perform a multivariate analysis to explore relationships
between the important variables in the dataset. (It is a good idea to explore
relations between numerical variables as well as relations between numerical
and categorical variables)
Cuisine vs Cost of the order
The cuisine with the highest median cost is French ($20.47)
12
Cuisine vs Food Preparation time
The cuisine with the longest median preparation time is Italian (28.0 minutes).
Day of the Week vs Delivery time
day_of_the_wee count mean std min 25% 50% 75% max
k
28.3400 2.89142
Weekday 547 4 8 24 26 28 31 33
22.4700 4.62893
Weekend 1351 2 8 15 18.5 22 27 30
13
observations on the revenue generated by the
restaurants:
The Restaurant with the Highest sales is Shake Shack
the Restaurant with the lowest sales is Five Guys Burgers and Fries
The Most important observation is that the Top Five Restaurants received maximum
orders are the one's making maximum revenue
On arranging it in descending we can get the top 5 least ordered restaurants
Rating vs Delivery time
General trend is that with decreasing delivery time the ratings are increasing
Also, we have large amount of NaN data which make significantly interfere our
conclusions (is the rating s are given)
Rating vs Food preparation time
14
rating count mean std min 25% 50% 75% max
27.4308 4.76849
3 188 5 1 20 23 27 32 35
27.3963 4.62077
4 386 7 6 20 23 27 31.75 35
27.3554 4.69381
5 588 4 3 20 23 27.5 32 35
Not 27.3573 4.56294
given 736 4 2 20 23 27 31 35
For 736 orders the rating were not give, if we able to get the rating of those it would be
valuable for our analysis.
Also, we can see 188 orders got only 3 rating, we need to find the reason behind that and
improve the customer experience.
Rating vs Cost of the order
Rating Count Mean Std Min 25% 50% 75% Max
3 188 16.22335 7.840886 4.75 12.0425 14.12 21.83 33.37
4 386 16.71034 7.632996 4.75 12.13 14.16 22.7875 35.41
5 588 16.9657 7.448696 4.47 12.13 15.205 22.8 33.03
Not
736 16.08534 7.32754 4.66 11.8275 14.07 21.5 34.19
given
We can clearly see that customers prefer quality over cost.
15
Question 13: The company wants to provide a promotional offer in the
advertisement of the restaurants. The condition to get the offer is that the
restaurants must have a rating count of more than 50 and the average rating
should be greater than 4. Find the restaurants fulfilling the criteria to get the
promotional offer.
Only 4 restaurants meet the requirements to qualify for the promotional offer.
They all have more than 50 rating count and have an average rating greater than 4.
1. The Meatball Shop
2. Blue Ribbon Fried Chicken
3. Shake Shack
4. Blue Ribbon Sushi
Question 14: The company charges the restaurant 25% on the orders
having cost greater than 20 dollars and 15% on the orders having cost greater
than 5 dollars. Find the net revenue generated by the company across all
orders.
The net revenue is around 6166.3 dollars
Question 15: The company wants to analyze the total time required to
deliver the food. What percentage of orders take more than 60 minutes to
get delivered from the time the order is placed? (The food has to be prepared
and then delivered.
Percentage of orders with total delivery time > 60 minutes: 10.54 %
16
Question 16: The company wants to analyse the delivery time of the
orders on weekdays and weekends. How does the mean delivery time vary
during weekdays and weekends?
The mean delivery time on weekdays is around 28 minutes
The mean delivery time on weekend is around 22 minutes
Actionable Insights and Recommendations
Actionable Insights:
There a total of 1898 Orders placed in the given frame.
Total of 178 restaurants serving 14 different cuisines to its customer's.
1 - American 2 - Japanese 3 - Italian 4 - Chinese 5 - Mexican and Indian These are the
most ordered cuisines across.
Orders on the Weekend > Orders on Weekdays This maybe because on Weekend
people maybe in leave and they tend to order or They wanted to have a different
type of cuisine on the weekend.
The Median time for Food Delivery is 25 Minutes and the maximum time taken in 33
Minutes.
Comparing with all cuisines French cuisine ($20.47) has highest median. From this we
can say that the French menu is costly.
The cuisine with longest food preparation median is Italian (28.0 minutes).
General trend is that with decreasing delivery time the ratings are increasing
Only 4 restaurants are eligible for promotional vouchers
17
Recommendations:
The top 5 restaurants generate the maximum revenue for the Food Hub, so the
company can give promotional discounts to those customers.
Since the order count is more on weekends the company can try to increase the
delivery partners on the weekend to manage the demand and shorten the delivery
time more.
Set up a Query or rating system at end of each order. which will help the customers
give the feedback for the restaurant, which indeed will help in improving the
business.
Can check on the lowest rated restaurants and get the feedback from customers to
improve the standards of service.
The most ordered cuisines are American and Japanese, so we can give additional
discounts on those orders.
Connect with the customer of higher orders and get their valuable feedback. This
also help's in getting the insights and make the customer feel more valuable.
We can give some kind of award/recognition to the top-rated restaurants on the
basis of rating, delivery time and feedbacks. which will also help the restaurant keep
growing and make the other restaurants to strive for betterment.
Some orders are taking more than 30+ minutes to get delivered. we can analyse on
the cause of this and try to lower it to the average time.
Since the orders are less on weekdays, we need to check why is that so and try to
give promotional offers in general on those days to increase the orders.
On analysing the most ordered items on each day we can keep the inventory ready
and stocked which will increase the preparation time and reduce the delivery time.
18
19