library(leaflet)
m <-leaflet()
m<-addTiles(m)
#m <- addMarkers(m, lng=174.768, lat=-36.852, popup="The birthplace of R")
m <- addMarkers(m, lng=139.76717, lat=35.68146, popup="Tokyo Station")
m <- addMarkers(m, lng=139.70998012558647, lat=35.66074602247774, popup="Aogaku")
m <- addMarkers(m, lng=135.7854276536189, lat=35.002523999468124, popup="Kiyomizu temple")
m
library(leaflet)
m<-leaflet() %>%
addTiles() %>%
addMarkers(lng=174.768, lat=-36.852, popup="The birthplace of R") %>%
addMarkers(lng=139.76727500369722, lat=35.68207281264243, popup="Tokyo Station")
m
library(leaflet)
library(readr)
trade <- read_csv("trade.csv")
## Rows: 5 Columns: 7
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: ","
## chr (2): origins, destinations
## dbl (5): import, longitude.x, latitude.x, longitude.y, latitude.y
##
## ℹ Use `spec()` to retrieve the full column specification for this data.
## ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
x<-leaflet() %>%
addTiles() %>%
addMarkers(lng=trade$longitude.x, lat=trade$latitude.x, popup=trade$origins)
x
library(leaflet)
library(readr)
trade <- read_csv("trade.csv")
## Rows: 5 Columns: 7
## ── Column specification ────────────────────────────────────────────────────────
## Delimiter: ","
## chr (2): origins, destinations
## dbl (5): import, longitude.x, latitude.x, longitude.y, latitude.y
##
## ℹ Use `spec()` to retrieve the full column specification for this data.
## ℹ Specify the column types or set `show_col_types = FALSE` to quiet this message.
x<-leaflet()
x<-addTiles(x)
x<-addCircles(x,lng = trade$longitude.x,lat = trade$latitude.x,weight = 1,radius = trade$import*100000,popup = trade$origins)
x