eyk801 / mp3

For MiniProject 3 in SDS192
0 stars 0 forks source link

Plotting #10

Open jlin47 opened 6 years ago

jlin47 commented 6 years ago

pal <- colorNumeric( palette = "Blues", domain = contours$ELEV_M)

factpal <- colorFactor(topo.colors(3), trails_1$Difficult)

require(leaflet)

leaflet()%>% addTiles()%>% addPolylines(data=trails_2, weight = 5, fillOpacity = 0.5, popup = ~ name, group = "Structures", color = ~factpal(Difficulty))%>% addMarkers(data = macleish_layers[["landmarks"]], popup = ~ Label, group = "Structures")%>% addPolylines(data = contours, weight = 1, fillOpacity = 0.1, color = ~pal(ELEV_M))