Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
UMR-ASTRE
Covid19-Mortality-Visualisation
Commits
45ddd4da
Commit
45ddd4da
authored
Sep 17, 2020
by
Facundo Muñoz
®️
Browse files
Fix visualisation of maxdr in Table 1.3.
Need to multiply by 1e5 so it displays the deat rate per 100k inhabs.
parent
c79ac84c
Pipeline
#17728
passed with stage
in 3 minutes and 22 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/Covid19MortalityEurope.Rmd
View file @
45ddd4da
...
...
@@ -1249,18 +1249,13 @@ cap <- paste("Median values of indicators used to define the country",
cap.col1 <- paste(cap, labcol1)
tab <- as.data.frame(zd[, 1:5])
synth <- do.call(
"rbind",
by(tab,
list(Class = zd$Class),
FUN = function(x)
apply(x, 2, median)))
res <- as.data.frame(synth[order(synth[,2]),])
kable(
data.frame(Category = rownames(res), res),
zd %>%
select(Category = Class, 1:5) %>%
group_by(Category) %>%
summarise_if(is.numeric, median) %>%
arrange(maxdr) %>%
mutate(maxdr = 1e5 * maxdr) %>% # max death rate per 100h inhabs.
kable(
format = "pandoc",
booktabs = T,
row.names = F,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment