You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have checked challenges 1 to 3. There is no need to add tidyverse. I have changed tidyverse code for base R ones. For instance, in the chunk below I have switched mutate with transform and arrange with sort_by :
if (require("waffle")) {
day1 <- Cholera |>
transform(newcholeradeaths = cholera_deaths/40) |>
sort_by(~water) |>
ggplot(aes(fill=water,values=newcholeradeaths)) +
geom_waffle(radius=grid::unit(0.4,"npc"),
size=.25) +
theme_void() +
labs(title="Deaths from Cholera in London in 1849",
subtitle="40 Deaths per Square",
caption="Data from William Farr's initial report, where he concluded
elevation \nwas the factor in the spread of plague",
fill="Water Source") +
scale_fill_brewer(palette="Dark2") +
theme(legend.position="bottom",
panel.background=element_rect(color="white"))
day1
}
Activity
lfpdroubi commentedon May 21, 2025
I have checked challenges 1 to 3. There is no need to add tidyverse. I have changed tidyverse code for base R ones. For instance, in the chunk below I have switched
mutatewithtransformandarrangewithsort_by: