library(RColorBrewer)
colours <- brewer.pal(10, "Paired")
data <- data.frame(VaccinationStatus = c("SecondDose", "FirstDose", "Unvaccinated", "lessThan4"),Population = c(6505475, 555389, 1086407, 402888), NewCases = c(5745,241,1227,169), TotalCases28 = c(236159,12654,35197,7549), NewHospitalizations = c(277,11,143,11), TotalHosp = c(3571,144,1485,129))
data$PopPercept <- (data$Population / sum(data$Population))*100
data$RatioTCases <-(data$TotalCases28 / sum(data$TotalCases28))*100
data$RatioTHosp <- (data$TotalHosp / sum(data$TotalHosp))*100
data
##   VaccinationStatus Population NewCases TotalCases28 NewHospitalizations
## 1        SecondDose    6505475     5745       236159                 277
## 2         FirstDose     555389      241        12654                  11
## 3      Unvaccinated    1086407     1227        35197                 143
## 4         lessThan4     402888      169         7549                  11
##   TotalHosp PopPercept RatioTCases RatioTHosp
## 1      3571  76.086012   80.998700  67.010696
## 2       144   6.495657    4.340116   2.702196
## 3      1485  12.706278   12.071999  27.866391
## 4       129   4.712053    2.589184   2.420717
Population based representation of COVID-19 cases and hospitalizations by vaccination status in Quebec, Canada as of January 13th 2022. Representation values are taken as a difference in the proportion (%) of individuals belonging to a vaccination status group and their representation in the number of cases and hospitalizations (including ICU). Positive values indicate that a group is overrepresented, meaning that more people have a positive case or are hospitalized than their proportion of the population. Negative values represent an under representation.

Population based representation of COVID-19 cases and hospitalizations by vaccination status in Quebec, Canada as of January 13th 2022. Representation values are taken as a difference in the proportion (%) of individuals belonging to a vaccination status group and their representation in the number of cases and hospitalizations (including ICU). Positive values indicate that a group is overrepresented, meaning that more people have a positive case or are hospitalized than their proportion of the population. Negative values represent an under representation.