Skip to content

Commit

Permalink
Update notebook 84 (#603)
Browse files Browse the repository at this point in the history
* Update notebook 84

* Update binder link
  • Loading branch information
giswqs authored Nov 13, 2023
1 parent a44d4c4 commit f6c08f0
Show file tree
Hide file tree
Showing 2 changed files with 71 additions and 1 deletion.
35 changes: 35 additions & 0 deletions docs/notebooks/84_read_parquet.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,20 @@
"leafmap.view_vector(gdf, get_fill_color=[0, 0, 255, 128])"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![vector](https://i.imgur.com/HRtpiVd.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Alternatively, you can specify a color map to visualize the data."
]
},
{
"cell_type": "code",
"execution_count": null,
Expand Down Expand Up @@ -169,6 +183,20 @@
"leafmap.view_vector(gdf, color_column='WETLAND_TYPE', color_map=color_map, opacity=0.5)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![vector-color](https://i.imgur.com/Ejh8hK6.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Display a legend for the data."
]
},
{
"cell_type": "code",
"execution_count": null,
Expand All @@ -177,6 +205,13 @@
"source": [
"leafmap.Legend(title=\"Wetland Type\", legend_dict=color_map)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![legend](https://i.imgur.com/fxzHHFN.png)"
]
}
],
"metadata": {
Expand Down
37 changes: 36 additions & 1 deletion examples/notebooks/84_read_parquet.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"[![image](https://studiolab.sagemaker.aws/studiolab.svg)](https://studiolab.sagemaker.aws/import/github/opengeos/leafmap/blob/master/examples/notebooks/84_read_parquet.ipynb)\n",
"[![image](https://img.shields.io/badge/Open-Planetary%20Computer-black?style=flat&logo=microsoft)](https://pccompute.westeurope.cloudapp.azure.com/compute/hub/user-redirect/git-pull?repo=https://github.com/opengeos/leafmap&urlpath=lab/tree/leafmap/examples/notebooks/84_read_parquet.ipynb&branch=master)\n",
"[![image](https://colab.research.google.com/assets/colab-badge.svg)](https://githubtocolab.com/opengeos/leafmap/blob/master/examples/notebooks/84_read_parquet.ipynb)\n",
"[![image](https://mybinder.org/badge_logo.svg)](https://gishub.org/leafmap-binder)\n",
"[![image](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/opengeos/leafmap/HEAD)\n",
"\n",
"**Reading GeoParquet files and visualizing vector data interactively**\n",
"\n",
Expand Down Expand Up @@ -142,6 +142,20 @@
"leafmap.view_vector(gdf, get_fill_color=[0, 0, 255, 128])"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![vector](https://i.imgur.com/HRtpiVd.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Alternatively, you can specify a color map to visualize the data."
]
},
{
"cell_type": "code",
"execution_count": null,
Expand Down Expand Up @@ -169,6 +183,20 @@
"leafmap.view_vector(gdf, color_column='WETLAND_TYPE', color_map=color_map, opacity=0.5)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![vector-color](https://i.imgur.com/Ejh8hK6.png)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Display a legend for the data."
]
},
{
"cell_type": "code",
"execution_count": null,
Expand All @@ -177,6 +205,13 @@
"source": [
"leafmap.Legend(title=\"Wetland Type\", legend_dict=color_map)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"![legend](https://i.imgur.com/fxzHHFN.png)"
]
}
],
"metadata": {
Expand Down

0 comments on commit f6c08f0

Please sign in to comment.