Skip to content

Arbitrary Shapefile Visualization #173

@rand5

Description

@rand5

I am stuck on the PlotlyJS equivalent of the following example found here on the Plots.jl page:

using PlotRecipes, Shapefile
dir = "https://github.com/nvkelso/natural-earth-vector/raw/master/110m_physical/"
fn = "ne_110m_land.shp"
run(`wget $dir/$fn -P /tmp/`)
shp = open("/tmp/$fn") do fd
    read(fd, Shapefile.Handle)
end
plot(shp)

I tried out the following mapbox example here

mapbox_access_token = "pk.eyJ1IjoiY2hlbHNlYXBsb3RseSIsImEiOiJjaXFqeXVzdDkwMHFrZnRtOGtlMGtwcGs4In0.SLidkdBMEap9POJGIe1eGw"

data = scattermapbox(
    lat=[45.5017], lon=[-73.5673], text=["Montreal"],
    mode="markers", marker_size=14, 
)

layout = Layout(
    autosize=true, hovermode="closest",
    mapbox=attr(
        accesstoken=mapbox_access_token,
        bearing=0,
        center_lat=45, center_lon=-73,
        pitch=0,
        zoom=5
    )
)

plot([data], layout)

and the maps/plots via mapbox look great, but I wouldn't say they look sleek, or at least not as sleek as some of the examples here.

My goal is to visualize (and plot over) the zip code shapefile here on the Census Bureau website.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions