devtools::install_github("Kolpashnikova/package_R_usamap")
library(usamap)
Draws an interactive US map for state-level data.
usamap(df)
usamap(df, startCOlor = NULL, endCOlor = NULL)
df json data with keys as two-letter state codes and values.
startColor the RGB color list for the lower values of gradient. The default is blue.
endColor the RGB color list for higher values of gradient. The default is red.
You can try the interactive demo here: (https://kolpashnikova.github.io/usmap)
Kolpashnikova, Kamila. (2022). US Map Visualization for Time-Use Data in R. Toronto,ON: York University.