Timeline for Interactive R maps that work well on mobile, with inset AK and HI?
Current License: CC BY-SA 4.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
2 days ago | history | edited | Jan |
edited tags
|
|
Jun 12 at 16:10 | history | edited | Rine | CC BY-SA 4.0 |
Added code and a link
|
Jun 12 at 16:02 | comment | added | Rine | Hi, @cristian-vargas! I am really just looking for a pinch-zoom and pop-up on tap interactivity, as I tried to note in my question. AFAIK (and after spending a bunch of time looking through Plotly boards), it seems that Plotly in R doesn't do pinch-zoom on mobile. I'll edit to post some code in the next few minutes, as well as a prototype map, and I don't need basemap tiles, honestly—just state outlines/states is wonderful. Thank you for the shift_geometry option, too, I'll give it a try shortly! | |
Jun 11 at 3:00 | comment | added | cristian-vargas |
Could you edit your post to include the plotly or leaflet code that you've tried so we can get a better idea of the kind of interactivity you're looking for? Either package can do this if fed the right data format (e.g., sf or GeoJSON). For instance, you could use my_data <- tigris::states() |> tigris::shift_geometry() |> sf::st_transform(4326) and then plot this in leaflet with leaflet() |> addPolygons(data = my_data) . You may not be able to add basemap tiles, however, since Alaska and Hawaii will be shifted.
|
|
Jun 10 at 23:05 | review | Close votes | |||
Jun 15 at 0:05 | |||||
Jun 10 at 22:43 | history | asked | Rine | CC BY-SA 4.0 | created from wizard |