Analyzing the selected sample
On analyzing the data it turns out that restaurants in towards the middle of the city tend to do more better than restaurants away from the center mainly due to the infrastructure since a higher delivering rating means low waiting time for customer and on basis of Google’s satellite maps we have marked the whole city in 3 zones green,yellow,red .
Here we are Geo-coding all the restaurants which are
---
title: "Prashant's Zomato Data Analysis for Delhi NCR business owners"
output:
flexdashboard::flex_dashboard:
orientation: rows
vertical_layout: fill
source_code: embed
---
```{r setup, include=FALSE}
library(flexdashboard)
library(knitr)
library(DT)
library(ggplot2)
library(plotly)
library(dplyr)
library(openintro)
library(highcharter)
library(ggvis)
library(leaflet)
library(rpivotTable)
library(ggwordcloud)
library(tidyverse)
```
```{r}
data <- read.csv('C:\\Users\\Rajesh\\Downloads\\DelhiNCR Restaurants.csv',)
dining<- data%>% arrange(desc(data$Dining_Rating)) %>% slice(1:100)
delivery <- data%>% arrange(desc(data$Delivery_Rating)) %>% slice(1:100)
```
# Dining/Offline Oriented Restaurants
## Row
### Location Pricing for 2
Analyzing the selected sample
```{r}
bxonline<- ggplot(dining) +
aes(x = "", y = Pricing_for_2) +
geom_boxplot(fill = "#FF5555") +
ggthemes::theme_solarized()
finalofflinebox <- ggplotly(bxonline)
finalofflinebox
```
### Popular food items
```{r}
diningedited = dining%>% separate(Category, c('C1', 'C2', 'C3', 'C4', 'C5', 'C6'))
diningCATEGORY<- select(diningedited, starts_with("C"))
diningCATEGORY = data.frame(unlist(diningCATEGORY,)) %>% na.omit()
diningCATEGORYcount = as.data.frame(table(diningCATEGORY))
popularcategory<- ggplot(diningCATEGORYcount, aes(label = diningCATEGORY, size = Freq)) +
geom_text_wordcloud() +
theme_minimal()
popularcategory
```
### Popular Cuisines
```{r}
diningedited2 = dining%>% separate(Known_For2, c('C1', 'C2', 'C3', 'C4', 'C5', 'C6'))
diningKnown_For2<- select(diningedited2, 'C1', 'C2', 'C3', 'C4', 'C5', 'C6')
diningKnown_For2 = data.frame(unlist(diningKnown_For2,)) %>% na.omit()
diningKnown_For2count = as.data.frame(table(diningKnown_For2))
popularfooditems<- ggplot(diningKnown_For2count, aes(label = diningKnown_For2, size = Freq)) +
geom_text_wordcloud() +
theme_minimal()
popularfooditems
```
## Row
### Location
On analyzing the data it turns out that restaurants in towards the middle of the city tend to do more better than restaurants away from the center mainly due to the infrastructure since a higher delivering rating means low waiting time for customer and on basis of Google's satellite maps we have marked the whole city in 3 zones green,yellow,red .
```{r}
monline <- leaflet(dining)%>% addTiles() %>% addCircleMarkers(lat = dining$Latitude,lng = dining$Longitude,radius =(dining$Dining_Review_Count)/300, fill= "#FF5555")
monline
```
# Delivery/Cloud Kitchen oriented Restaurants
## Row
### Pricing for 2
```{r}
bxonffline<- ggplot(delivery) +
aes(x = "", y = Pricing_for_2) +
geom_boxplot(fill = "#FF5555") +
ggthemes::theme_solarized()
finalcloudbox <- ggplotly(bxonline)
finalcloudbox
```
### Popular food items
```{r}
deliveryedited = delivery%>% separate(Category, c('C1', 'C2', 'C3', 'C4', 'C5', 'C6'))
deliveryCATEGORY<- select(deliveryedited, starts_with("C"))
deliveryCATEGORY = data.frame(unlist(deliveryCATEGORY,)) %>% na.omit()
deliveryCATEGORYcount = as.data.frame(table(deliveryCATEGORY))
popularcategory<- ggplot(deliveryCATEGORYcount, aes(label = deliveryCATEGORY, size = Freq)) +
geom_text_wordcloud() +
theme_minimal()
popularcategory
```
### Popular food items
```{r}
deliveryedited2 = delivery%>% separate(Known_For2, c('C1', 'C2', 'C3', 'C4', 'C5', 'C6'))
deliveryKnown_For2<- select(deliveryedited2, 'C1', 'C2', 'C3', 'C4', 'C5', 'C6')
deliveryKnown_For2 = data.frame(unlist(deliveryKnown_For2,)) %>% na.omit()
deliveryKnown_For2count = as.data.frame(table(deliveryKnown_For2))
popularfooditems<- ggplot(deliveryKnown_For2count, aes(label = deliveryKnown_For2, size = Freq)) +
geom_text_wordcloud() +
theme_minimal()
popularfooditems
```
## ROW
### Location
Here we are Geo-coding all the restaurants which are
```{r}
mdelivery <- leaflet(delivery)%>% addTiles() %>% addCircleMarkers(lat = delivery$Latitude,lng = delivery$Longitude,radius = (dining$Delivery_Rating_Count)/300, fill= "#FF5555")
mdelivery
```