Hi y'all
I would be most grateful if anyone out there has written a simple code to categorize states in Democrat, Republican and Swing state in 2016. I have 4000+ observations that have states listed as numerical so if anyone already has a code to generate new variable and segregate the numeric state into D, R, or S (for 2016 results), that would be most helpful. Does anyone already have it? Thank you.