Timeline for Append more variables to a SpatialPolygonsDataFrame using R
Current License: CC BY-SA 4.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Aug 6, 2022 at 16:56 | comment | added | ma991ng | Here is the new question - gis.stackexchange.com/questions/437657/… | |
Aug 6, 2022 at 16:56 | vote | accept | ma991ng | ||
Aug 6, 2022 at 16:26 | comment | added | ma991ng | I see why that is a different question, and in hindsight that was the real question I should have been asking. | |
Aug 6, 2022 at 15:01 | comment | added | dimfalk |
Yeah, that's because these are two unrelated problems in my opinion. What you did here, was to join additional attributes on your spatial data with a 1:1 relation. That is your data basis now. Your next step would involve finding a grid representation for your polygons (= individual states) respecting their position with the number of cells being based on the value given in electoralVotesNumber . I'd open a new question covering this issue.
|
|
Aug 6, 2022 at 14:51 | comment | added | ma991ng |
Thank you @falk-env. I tried your approach using sp::merge but I ended up with same number of observations (51) instead of 538.
|
|
Aug 6, 2022 at 10:34 | history | answered | dimfalk | CC BY-SA 4.0 |