I'm trying to plot election results on the US map with the usmap package but even though the dataset is complete, I get plot that shows missing values for some states. The states are greyed out and I'm not sure why this is happening..
plot_usmap(data=data_total,values='percent_biden')+
scale_fill_continuous(low='red',high='blue',name='Percent for Biden')+
theme(legend.position='right')+
ggtitle(paste("Total Popular Vote of Final Results"))
You are incorrectly assuming that
usmap
will infer any format for state names. For instance, both of these produce a working map,whereas inferring from your pic of data, you are trying
So I believe you need to clean up your data and fix your state names.