DALY_list {DALY} | R Documentation |
Make list of ‘DALY’ objects
Description
This function produces a list of DALY objects and assigns class
'DALY_list'
to it. Methods are available to print and plot the
resulting object.
Usage
DALY_list(...)
## S3 method for class 'DALY_list'
print(x, ...)
## S3 method for class 'DALY_list'
plot(x, prob = 0.95, sort = TRUE, names = NULL,
bars = TRUE, col = c("grey90", "white"),
error_bars = TRUE, eb_col = "black",
grid = TRUE, ...)
Arguments
... |
In |
x |
Object of class |
prob |
Probability span by DALY error bar;
defaults to |
sort |
Should values be sorted from high to low?
defaults to |
names |
Vector of names to be plotted on the y-axis. If this argument
is |
bars |
Should YLL/YLD bars be plotted?
defaults to |
col |
Color of YLL and YLD barplot;
defaults to |
error_bars |
Should DALY error bars be plotted?
defaults to |
eb_col |
Color of DALY error bars; defaults to black |
grid |
Should a vertical grid be plotted?
defaults to |
Value
An object of S3 class 'DALY_list'
.
Author(s)
See Also
getDALY
print.DALY
plot.DALY
scatterplot
DALYcalculator
(for a brief description of the DALY Calculator)
DALYmanual
(for a more comprehensive overview)
Examples
## Not run:
##= 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]"))
## End(Not run)