##= load NCC example ======================================
setDALYexample(1)
##= calculate DALYs under different scenarios =============
ncc_00 <- getDALY(aw = FALSE, dr = 0)
ncc_03 <- getDALY(aw = FALSE, dr = 0.03)
ncc_13 <- getDALY(aw = TRUE, dr = 0.03)
##= store results as 'DALY_list' ==========================
ncc <- DALY_list(ncc_00, ncc_03, ncc_13)
##= barplot of different scenarios ========================
par(mar = c(4, 4, 1, 1) + .5)
plot(ncc, names = c("DALY[0,0]", "DALY[0,0.03]", "DALY[1,0.03]"))Run the code above in your browser using DataLab