Death by Age

Sourav

4 December 2017

Objective

The output of the application is a bar chart with the input parameter being the population set which the user can chose from the dropdown list

The dropdown list contains the following options

The way it works

After taking the input elemtnts the application would create a bar chart with the age group in the X axis and the Death Rate per 1000 in the Y axis

Every Age group is denoted by a seperate colour bar

Every time the drop down is selected, the bar plot will get updated and so will the total deaths in the bottom column

The Main code and data set that was used

library(datasets)
data("VADeaths")
summary(VADeaths)
##    Rural Male     Rural Female     Urban Male     Urban Female  
##  Min.   :11.70   Min.   : 8.70   Min.   :15.40   Min.   : 8.40  
##  1st Qu.:18.10   1st Qu.:11.70   1st Qu.:24.30   1st Qu.:13.60  
##  Median :26.90   Median :20.30   Median :37.00   Median :19.30  
##  Mean   :32.74   Mean   :25.18   Mean   :40.48   Mean   :25.28  
##  3rd Qu.:41.00   3rd Qu.:30.90   3rd Qu.:54.60   3rd Qu.:35.10  
##  Max.   :66.00   Max.   :54.30   Max.   :71.10   Max.   :50.00

Slide with a sample plot and code

colors = c("blue", "light blue ", "yellow", "green", "purple")
barplot(VADeaths[,1], 
            main="Rural Male",
            ylab="Death Rate per 1000 population",
            xlab="Age Group",col = colors)