Creating Maps, Leaflet not working

I'm learning through, while creating maps using "leaflet"
The map do not get plotted.

Hi and welcome! You haven't added a basemap or any markers to your leaflet map, so I wouldn't expect anything to be displayed. I would recommend starting with the examples on the Leaflet for R site. They have code for many different types of leaflet maps.

For instance, are you able to make this first introductory leaflet map?


leaflet() %>%
  addTiles() %>%  
  addMarkers(lng=174.768, lat=-36.852, popup="The birthplace of R")
1 Like

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

You've created an object here called map. To view it you would need enter map into the console for it to print. It will then show up in the Viewer pane of RStudio

Thank you for the response.

Well, I wasn't even able to

do the same as on the shown in learning course.

should I be getting the map in the "Plot" section?