'data.frame': 4188 obs. of 19 variables:
$ SUBDIVISION: chr "Andaman & Nicobar Islands" "Andaman & Nicobar Islands" "Andaman & Nicobar Islands" "Andaman & Nicobar Islands" ...
$ YEAR : int 1901 1902 1903 1904 1905 1906 1907 1908 1910 1911 ...
$ JAN : num 49.2 0 12.7 9.4 1.3 ...
$ FEB : num 87.1 159.8 144 14.7 0 ...
$ MAR : num 29.2 12.2 0 0 3.3 ...
$ APR : num 2.3 0 1 202.4 26.9 ...
$ MAY : num 529 446 235 304 280 ...
$ JUN : num 518 537 480 495 629 ...
$ JUL : num 365 229 728 502 369 ...
$ AUG : num 481 754 327 160 330 ...
$ SEP : num 333 666 339 820 297 ...
$ OCT : num 388 197 181 222 261 ...
$ NOV : num 558.2 359 284.4 308.7 25.4 ...
$ DEC : num 33.6 160.5 225 40.1 344.7 ...
$ ANNUAL : num 3373 3521 2957 3080 2567 ...
$ JF : num 136.3 159.8 156.7 24.1 1.3 ...
$ MAM : num 560 458 236 507 310 ...
$ JJAS : num 1696 2186 1874 1978 1625 ...
$ OND : num 980 717 691 571 631 ...
SUBDIVISION YEAR JAN FEB
Length:4188 Min. :1901 Min. : 0.00 Min. : 0.0
Class :character 1st Qu.:1930 1st Qu.: 0.60 1st Qu.: 0.5
Mode :character Median :1959 Median : 5.95 Median : 6.5
Mean :1959 Mean : 18.94 Mean : 21.6
3rd Qu.:1988 3rd Qu.: 22.00 3rd Qu.: 26.6
Max. :2017 Max. :583.70 Max. :403.5
NA's :4 NA's :3
MAR APR MAY JUN
Min. : 0.00 Min. : 0.00 Min. : 0.00 Min. : 0.4
1st Qu.: 1.00 1st Qu.: 3.00 1st Qu.: 8.60 1st Qu.: 70.8
Median : 7.90 Median : 15.45 Median : 36.90 Median : 138.8
Mean : 27.41 Mean : 43.07 Mean : 85.66 Mean : 230.1
3rd Qu.: 31.38 3rd Qu.: 49.65 3rd Qu.: 97.80 3rd Qu.: 305.0
Max. :605.60 Max. :595.10 Max. :1168.60 Max. :1609.9
NA's :6 NA's :4 NA's :3 NA's :5
JUL AUG SEP OCT
Min. : 0.0 Min. : 0.0 Min. : 0.1 Min. : 0.00
1st Qu.: 175.6 1st Qu.: 155.8 1st Qu.: 100.4 1st Qu.: 14.60
Median : 285.0 Median : 258.5 Median : 173.7 Median : 65.20
Mean : 347.0 Mean : 289.7 Mean : 197.3 Mean : 95.32
3rd Qu.: 418.5 3rd Qu.: 377.6 3rd Qu.: 266.1 3rd Qu.:148.30
Max. :2362.8 Max. :1664.6 Max. :1222.0 Max. :948.30
NA's :7 NA's :4 NA's :6 NA's :7
NOV DEC ANNUAL JF
Min. : 0.0 Min. : 0.00 Min. : 62.3 Min. : 0.00
1st Qu.: 0.6 1st Qu.: 0.10 1st Qu.: 803.0 1st Qu.: 4.00
Median : 9.4 Median : 3.00 Median :1120.3 Median : 18.90
Mean : 39.5 Mean : 18.97 Mean :1409.4 Mean : 40.52
3rd Qu.: 45.3 3rd Qu.: 17.50 3rd Qu.:1643.6 3rd Qu.: 50.17
Max. :648.9 Max. :617.50 Max. :6331.1 Max. :699.50
NA's :11 NA's :10 NA's :26 NA's :6
MAM JJAS OND
Min. : 0.0 Min. : 57.4 Min. : 0.0
1st Qu.: 24.0 1st Qu.: 573.9 1st Qu.: 34.0
Median : 74.8 Median : 880.6 Median : 97.7
Mean : 155.8 Mean :1063.9 Mean : 153.6
3rd Qu.: 196.9 3rd Qu.:1287.5 3rd Qu.: 211.8
Max. :1745.8 Max. :4536.9 Max. :1252.5
NA's :9 NA's :10 NA's :13
SUBDIVISION YEAR JAN FEB MAR APR MAY JUN JUL AUG
1 Andaman & Nicobar Islands 1901 49.2 87.1 29.2 2.3 528.8 517.5 365.1 481.1
2 Andaman & Nicobar Islands 1902 0.0 159.8 12.2 0.0 446.1 537.1 228.9 753.7
3 Andaman & Nicobar Islands 1903 12.7 144.0 0.0 1.0 235.1 479.9 728.4 326.7
4 Andaman & Nicobar Islands 1904 9.4 14.7 0.0 202.4 304.5 495.1 502.0 160.1
5 Andaman & Nicobar Islands 1905 1.3 0.0 3.3 26.9 279.5 628.7 368.7 330.5
6 Andaman & Nicobar Islands 1906 36.6 0.0 0.0 0.0 556.1 733.3 247.7 320.5
SEP OCT NOV DEC ANNUAL JF MAM JJAS OND
1 332.6 388.5 558.2 33.6 3373.2 136.3 560.3 1696.3 980.3
2 666.2 197.2 359.0 160.5 3520.7 159.8 458.3 2185.9 716.7
3 339.0 181.2 284.4 225.0 2957.4 156.7 236.1 1874.0 690.6
4 820.4 222.2 308.7 40.1 3079.6 24.1 506.9 1977.6 571.0
5 297.0 260.7 25.4 344.7 2566.7 1.3 309.7 1624.9 630.8
6 164.3 267.8 128.9 79.2 2534.4 36.6 556.1 1465.8 475.9
---
title: "EDA for Rainfall Dataset"
output:
flexdashboard::flex_dashboard:
orientation: rows
vertical_layout: scroll
theme: flatly
social: menu
source_code: embed
navbar:
- { title: "Dataset Description", href: "#dataset-description" }
- { title: "Univariate Analysis", href: "#univariate-analysis" }
- { title: "Bivariate Analysis", href: "#bivariate-analysis" }
- { title: "Multivariate Analysis", href: "#multivariate-analysis" }
---
```{r setup, include=FALSE}
library(flexdashboard)
library(ggplot2)
library(dplyr)
library(DT)
rainfall <- read.csv("/cloud/project/rainfall.csv")
```
## Dataset Description {.tabset .active} {#dataset-description}
### View of dataset
```{r}
datatable(rainfall, extensions = 'Buttons', options = list(dom='Bfrtip', buttons=c('copy','csv','print','pdf')))
```
### About the Dataset
```{r}
str(rainfall)
```
### Summary of the dataset
```{r}
summary(rainfall)
```
### Head of Dataset
```{r}
head(rainfall)
```
## Univariate Analysis {.tabset} {#univariate-analysis}
### Histogram for Annual Rainfall
```{r}
ggplot(rainfall, aes(x = ANNUAL)) +
geom_histogram(fill = "lightblue", color = "black", bins = 30) +
geom_vline(aes(xintercept = mean(ANNUAL, na.rm = TRUE)), color = "red", lwd = 1) +
labs(title = "Histogram of Annual Rainfall", x = "Annual Rainfall (mm)")
```
### Histogram for June Rainfall
```{r}
ggplot(rainfall, aes(x = JUN)) +
geom_histogram(fill = "lightgreen", color = "black", bins = 30) +
geom_vline(aes(xintercept = mean(JUN, na.rm = TRUE)), color = "red", lwd = 1) +
labs(title = "Histogram of June Rainfall", x = "June Rainfall (mm)")
```
### Histogram for September Rainfall
```{r}
ggplot(rainfall, aes(x = SEP)) +
geom_histogram(fill = "lightcoral", color = "black", bins = 30) +
geom_vline(aes(xintercept = mean(SEP, na.rm = TRUE)), color = "red", lwd = 1) +
labs(title = "Histogram of September Rainfall", x = "September Rainfall (mm)")
```
## Bivariate Analysis {.tabset} {#bivariate-analysis}
### Box Plot for Annual Rainfall by Subdivision
```{r}
ggplot(rainfall, aes(x = SUBDIVISION, y = ANNUAL)) +
geom_boxplot(fill = 'lightblue', color = 'black') +
labs(title = "Box Plot of Annual Rainfall by Subdivision", x = "Subdivision", y = "Annual Rainfall (mm)") +
theme(axis.text.x = element_text(angle = 90, hjust = 1))
```
### Box Plot for June Rainfall by Subdivision
```{r}
ggplot(rainfall, aes(x = SUBDIVISION, y = JUN)) +
geom_boxplot(fill = 'lightgreen', color = 'black') +
labs(title = "Box Plot of June Rainfall by Subdivision", x = "Subdivision", y = "June Rainfall (mm)") +
theme(axis.text.x = element_text(angle = 90, hjust = 1))
```
### Scatter Plot of Annual Rainfall vs Year
```{r}
ggplot(rainfall, aes(x = YEAR, y = ANNUAL)) +
geom_point(color = "blue") +
labs(title = "Scatter Plot of Annual Rainfall vs Year", x = "Year", y = "Annual Rainfall (mm)")
```
## Multivariate Analysis {.tabset} {#multivariate-analysis}
### Scatter Plot for June Rainfall vs September Rainfall
```{r}
ggplot(rainfall, aes(x = JUN, y = SEP)) +
geom_point(color = "purple") +
labs(title = "Scatter Plot of June vs September Rainfall", x = "June Rainfall (mm)", y = "September Rainfall (mm)")
```
### Scatter Plot for Annual Rainfall vs June Rainfall
```{r}
ggplot(rainfall, aes(x = JUN, y = ANNUAL)) +
geom_point(color = "orange") +
labs(title = "Scatter Plot of Annual Rainfall vs June Rainfall", x = "June Rainfall (mm)", y = "Annual Rainfall (mm)")
```