plot_sf.Rd
Plots the geometry in an sf tibble object. This is function isn't meant to actually be used in-practice (due to its simplicity, but is more so intended as a tutorial of writing and documenting R functions
plot_sf(sf_tibble)
sf_tibble | an sf tibble object with simple feature geometry in the 'geometry' column |
---|
Joe Zemmels
#> Warning: cannot open compressed file '../data_raw/dataRaw_povertyBySexAge_acs5_2019.rda', probable reason 'No such file or directory'#> Error in readChar(con, 5L, useBytes = TRUE): cannot open the connection#> Warning: package 'dplyr' was built under R version 4.0.3#> #>#>#> #>#>#> #>#> Warning: package 'ggplot2' was built under R version 4.0.5dataRaw_povertyBySexAge_acs5_2019 %>% sf::st_as_sf() %>% #seems to throw an error unless this conversion happens filter(variable == "B17001_002") %>% #filter first to reduce join time left_join(acs5_2019_variableNames, by = c("variable" = "name")) %>% dspgWork::plot_sf() + #returns a ggplot object, so can use ggplot functions scale_fill_gradient(low = "white",high = "black") + theme_minimal() + labs(title = "Income in the last 12 months below poverty level per county", fill = "Count")#> Error in eval(lhs, parent, parent): object 'dataRaw_povertyBySexAge_acs5_2019' not found