Skip to content

Commit 4a96d56

Browse files
Notebook 16: Rasterstats section fix
1 parent cc8d0a6 commit 4a96d56

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

16_OPTIONAL_Introduction_to_Raster_Data.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -749,10 +749,10 @@
749749
"metadata": {},
750750
"outputs": [],
751751
"source": [
752-
"with rasterio.open('notebook_data/raster/nlcd2011_sf.tif') as src:\n",
752+
"with rasterio.open('outdata/nlcd2011_sf_cropped.tif') as src:\n",
753753
" affine = src.transform\n",
754754
" array = src.read(1)\n",
755-
" df_zonal_stats = pd.DataFrame(zonal_stats(tracts_gdf_sf, array, affine=affine, stats=['majority', 'unique']))"
755+
" df_zonal_stats = pd.DataFrame(zonal_stats(tracts_gdf_sf, array, affine=affine, stats=['majority', 'unique'], nodata=-999))"
756756
]
757757
},
758758
{

0 commit comments

Comments
 (0)