Skip to content

Instantly share code, notes, and snippets.

@databyjp
Created November 2, 2020 06:15
Show Gist options
  • Save databyjp/7dc37cefde364c4c1a830bf8cd3b72ae to your computer and use it in GitHub Desktop.
Save databyjp/7dc37cefde364c4c1a830bf8cd3b72ae to your computer and use it in GitHub Desktop.
fig = px.choropleth_mapbox(tmp_df, locations="fips", color="Median_Household_Income_2018",
range_color=[20000, 40000],
geojson=counties, color_continuous_scale=px.colors.sequential.Oranges[::-1], labels=labels)
fig.update_layout(mapbox_style="carto-positron",
mapbox_zoom=3.9, mapbox_center={"lat": 37.0902, "lon": -95.7129},
margin={"r": 0, "t": 0, "l": 0, "b": 0})
fig.update_traces(marker=dict(line=dict(width=0.3, color="gray")))
fig.show()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment