RPubs will retire in June 2027. Your existing documents will stay accessible through December 31, 2031
and Connect Cloud is the recommended home for new publishing. Read the blog post

Recently Published

ANLY 512 - Lab1
Apply 7
PreLab3_Solutions
UTS statistika lingkungan maheswarirahma
maheswari rahma sarvidya 2304220019 statistika dan sains data
Categories removed
Canada and Repatriated Travellers category removed. # Create bar chart of total COVID-19 cases by province # Removes both 'Canada' and 'Repatriated travellers' from the plot # You can also add other exclusions inside the filter() if needed plot_df <- covid_features |> filter(!province %in% c("Canada", "Repatriated travellers")) |> # Removes both unwanted categories group_by(province) |> summarise(total_cases = max(total_cases, na.rm = TRUE), .groups = "drop") |> arrange(desc(total_cases)) ggplot(plot_df, aes(x = reorder(province, -total_cases), y = total_cases, fill = province)) + geom_col(width = 0.7, show.legend = TRUE) + scale_y_continuous(labels = label_number(scale = 1e-6, suffix = " M")) + scale_fill_viridis_d(option = "turbo") + # Options: 'plasma', 'magma', 'inferno', 'cividis' labs( title = "Total COVID-19 Cases by Province in Canada", subtitle = "Cumulative totals (2020–2024)", x = "Province", y = "Total Reported Cases (Millions)", fill = "Province" ) + theme( axis.text.x = element_text(angle = 35, hjust = 1), plot.title = element_text(face = "bold", size = 16, hjust = 0.5), plot.subtitle = element_text(hjust = 0.5) )