cartographer

st <- mar::read_stations(year=2014) %>%
  filter(lat > 20) %>%
  select(id, cruise, date, lon, lat)



m %>% points_layer(data = st, x = "lon", y = "lat", size="torskur.kg")





library(svgPanZoom)
library(SVGAnnotation)
library(ggplot2)

svgPanZoom(
  svgPlot(
    #will put on separate line but also need show
    show(
      ggplot(data.frame(x=1:10,y=1:10),aes(x=x,y=y)) + geom_line()

    )
    # this is critical with svgPlot and grid graphics
    , addInfo = F
  )
)


library(choroplethr)
# from chorplethr documetation
data(df_pop_state)
m = state_choropleth(
  df_pop_state
  , title="US 2012 State Population Estimates"
  , legend="Population"
)
# take a peek
m
# would be so much more fun with pan and zoom
library(grid)
library(rjson)
svgPanZoom( m )
# if your map is big and hairy do this instead
svgPanZoom(
  svgPlot(
    show(m )
    # will have to manually size the svg device
    , height = 10, width = 16 )
)