———————————————————————————————————————————————————————

Introduction: In this report, we will explore and visualize the Blinkit dataset.We will perform basic descriptive analysis, and create simple visualizations.

———————————————————————————————————————————————————————

library(readxl)
clean_data <- read_excel("blinkit dataset.xlsx")
summary(clean_data)
##  Item_Identifier     Item_Weight     Item_Fat_Content   Item_Visibility  
##  Length:5001        Min.   : 4.555   Length:5001        Min.   :0.00000  
##  Class :character   1st Qu.: 8.890   Class :character   1st Qu.:0.02684  
##  Mode  :character   Median :12.800   Mode  :character   Median :0.05424  
##                     Mean   :12.959                      Mean   :0.06567  
##                     3rd Qu.:17.100                      3rd Qu.:0.09385  
##                     Max.   :21.350                      Max.   :0.32839  
##                     NA's   :818                                          
##   Item_Type            Item_MRP      Outlet_Identifier  Outlet_Size       
##  Length:5001        Min.   : 31.29   Length:5001        Length:5001       
##  Class :character   1st Qu.: 94.14   Class :character   Class :character  
##  Mode  :character   Median :143.32   Mode  :character   Mode  :character  
##                     Mean   :141.35                                        
##                     3rd Qu.:186.46                                        
##                     Max.   :266.89                                        
##                                                                           
##  Outlet_Location_Type Outlet_Type        Item_Outlet_Sales   feedback_id     
##  Length:5001          Length:5001        Min.   :   33.29   Min.   :    947  
##  Class :character     Class :character   1st Qu.:  846.90   1st Qu.:2576772  
##  Mode  :character     Mode  :character   Median : 1808.31   Median :5005913  
##                                          Mean   : 2188.34   Mean   :5013737  
##                                          3rd Qu.: 3091.97   3rd Qu.:7486363  
##                                          Max.   :11445.10   Max.   :9999293  
##                                                                              
##      rating       sentiment        
##  Min.   :1.000   Length:5001       
##  1st Qu.:3.000   Class :character  
##  Median :4.000   Mode  :character  
##  Mean   :3.345                     
##  3rd Qu.:4.000                     
##  Max.   :5.000                     
## 

———————————————————————————————————————————————————————-

#Ensuring loading of necessary libraries
library(dplyr)
## 
## Attaching package: 'dplyr'
## The following objects are masked from 'package:stats':
## 
##     filter, lag
## The following objects are masked from 'package:base':
## 
##     intersect, setdiff, setequal, union
library(ggplot2)
library(tidyverse)
## ── Attaching core tidyverse packages ──────────────────────── tidyverse 2.0.0 ──
## ✔ forcats   1.0.0     ✔ stringr   1.5.1
## ✔ lubridate 1.9.4     ✔ tibble    3.2.1
## ✔ purrr     1.0.2     ✔ tidyr     1.3.1
## ✔ readr     2.1.5
## ── Conflicts ────────────────────────────────────────── tidyverse_conflicts() ──
## ✖ dplyr::filter() masks stats::filter()
## ✖ dplyr::lag()    masks stats::lag()
## ℹ Use the conflicted package (<http://conflicted.r-lib.org/>) to force all conflicts to become errors

What is the distribution of product prices?

ggplot(clean_data, aes(x = Item_MRP)) +
  geom_histogram(binwidth = 10, fill = "skyblue", color = "black") +
  labs(title = "Distribution of Product Prices", x = "price", y = "count")

Result : The histogram shows that most product prices are clustered between 0 to 200, with fewer products priced above 200. The distribution is slightly right-skewed, indicating some higher-priced products.

How do ratings distribute across products?

ggplot(clean_data, aes(x = rating)) +
  geom_histogram(binwidth = 0.5, fill = "purple", color = "white") +
  labs(title = "Distribution of Product Ratings", x = "Rating", y = "Count")

Result : The histogram shows that most product ratings are between 4 and 5, with a large number of products receiving high ratings. Lower ratings are much less common.

What is the average price by category?

clean_data %>%
  group_by(Item_Type) %>%
  summarise(Average_Price = mean(Item_MRP, na.rm = TRUE)) %>%
  ggplot(aes(x = reorder(Item_Type, -Average_Price), y = Average_Price)) +
  geom_bar(stat = "identity", fill = "forestgreen") +
  labs(title = "Average Price by category", x = "category", y = "average price") +
  coord_flip()

Result : The bar chart shows that certain categories like Seafood and Snack Foods have the highest average prices, while items like Dairy Products are priced lower.

How do ratings distribute across products?

ggplot(clean_data, aes(x = rating)) +
  geom_histogram(binwidth = 0.5, fill = "purple", color = "white") +
  labs(title = "Distribution of Product Ratings", x = "Rating", y = "Count")

Result : The histogram shows that most products have ratings between 4 and 5, with 4.5 being the most common. Very few products have ratings below 3.

How many outlets exist for each outlet size?

ggplot(clean_data, aes(x = Outlet_Size)) +
  geom_bar(fill = "steelblue") +
  labs(title = "Count of Outlets by Size", x = "Outlet Size", y = "Count") +
  theme_minimal()

Result : The bar plot shows that Medium-sized outlets are the most common, followed by Small outlets, while High outlet sizes are the least common.

What is the distribution of product visibility?

ggplot(clean_data, aes(x = Item_Visibility)) +
  geom_histogram(binwidth = 0.01, fill = "orchid", color = "black") +
  labs(title = "Distribution of Product Visibility", x = "Visibility", y = "Count") +
  theme_minimal()

Result : The histogram shows that most products have very low visibility, with a large concentration near 0 and very few products having high visibility values.

What is the count of items per outlet identifier (Outlet ID)?

ggplot(clean_data, aes(x = Outlet_Identifier)) +
  geom_bar(fill = "slateblue") +
  labs(title = "Item Count per Outlet", x = "Outlet ID", y = "Count") +
  theme_minimal()

Result :The bar plot shows that some outlets, like OUT045, have a higher number of items, while others have significantly fewer.

What is the most common item type in the data set?

clean_data %>%
  count(Item_Type, sort = TRUE) %>%
  ggplot(aes(x = reorder(Item_Type, n), y = n)) +
  geom_bar(stat = "identity", fill = "skyblue", color = "black") +
  labs(title = "Most Common Item Types", x = "Item Type", y = "Count") +
  theme_minimal() + 
  coord_flip()

Result :The bar plot shows that Fruits and Vegetables are the most common item type, followed by Snack Foods and Household products. Some categories have much fewer items.

Is there a correlation between Item MRP and Rating?

ggplot(clean_data, aes(x = Item_MRP, y = rating)) +
  geom_point(alpha = 0.5, color = "dodgerblue") +
  labs(title = "Relationship between Item MRP and Rating",
   x = "Item MRP", y = "Rating") +
  theme_minimal()

Result :The scatter plot shows no strong relationship between Item MRP and Rating — products across all price ranges tend to have similar ratings.

What is the distribution of item outlet sales in the data set?

ggplot(clean_data, aes(x = Item_Outlet_Sales)) +
  geom_histogram(binwidth = 500, fill = "skyblue", color = "black") +
  labs(title = "Distribution of Item Outlet Sales",
   x = "Sales (in currency units)", y = "Count of Items") +
  theme_minimal()

Result : The histogram shows that most products have low outlet sales, with the majority clustered below 6000 units, while very few products achieve very high sales.

Is there a relationship between customer sentiment and product rating in the data set?

ggplot(clean_data, aes(x = sentiment, y = rating)) +
  geom_boxplot(fill = "lightgreen", color = "black") +
  labs(title = "Product Ratings by Sentiment",
       x = "Sentiment", y = "Rating") +
  theme_minimal()

Result : The boxplot shows that products with positive sentiment generally have higher ratings, while negative sentiment products tend to have lower ratings.

Do sales vary with the type of outlet tier?

ggplot(clean_data, aes(x = Outlet_Location_Type, y = Item_Outlet_Sales)) +
  geom_jitter(width = 0.2, alpha = 0.5, color = "forestgreen") +
  labs(title = "Outlet Tier vs Item Outlet Sales",
       x = "Outlet Tier", y = "Item Outlet Sales") +
  theme_minimal()

Result : The jitter plot shows that outlets across all tiers have a wide range of sales, but Tier 3 outlets seem to have more items with higher sales compared to Tier 1 and Tier 2.

———————————————————————————————————————————————————————–

Summary and Findings

- Product Pricing: Most products are affordable, priced under 200 currency units, making them accessible to a wide range of customers.

- Product Ratings: The majority of products have high ratings between 4 and 5, indicating overall good customer satisfaction.

- Item Types: Fruits and Vegetables are the most common item types in the dataset, followed by Snack Foods and Household products.

- Outlet Sizes: Medium-sized outlets are the most frequent, suggesting that Blinkit prefers moderate-sized stores to optimize space and cost.

- Sales Distribution: Most items have low to moderate sales, with a few products achieving very high sales, creating a right-skewed distribution.

- Visibility: Most products have very low visibility, meaning they are less prominently displayed in stores.

- Sentiment vs. Rating: Products with positive sentiment are usually associated with higher ratings, showing that customer experience strongly impacts ratings.

- Price vs. Rating Correlation: There is no strong relationship between product price and customer ratings; expensive products are not necessarily rated better.

———————————————————————————————————————————————————————-

Summary : The analysis of the Blinkit dataset reveals that affordable, essential items (like fruits, vegetables, and snacks) form the core of Blinkit’s product strategy. Customer satisfaction is high, as reflected by strong ratings, regardless of product price. Sales are dominated by a few high-performing products, while most items sell in moderate quantities. Outlet sizing, product visibility, and customer sentiment all play important roles in the company’s operational and marketing strategies. This descriptive analysis provides valuable insights for further targeted marketing, stock optimization, and customer engagement strategies.

———————————————————————————————————————————————————————-