"plot.show(CEC, title='Mean pH between 0 and 5 cm deep in Senegal', cmap='gist_ncar')"
"plot.show(ph, title='Mean pH between 0 and 5 cm deep in Senegal', cmap='gist_ncar')"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
...
...
%% Cell type:markdown id: tags:
Obtaining a map segment from a WCS
====================
Obtaining a map segment is another operation greatly simplified by the [OWSLib](https://geopython.github.io/OWSLib/) package. This case is conducted from a pre-established bounding box.
This time a connection is made to the service for soil pH:
The `getCoverage` method can now be used to fetch the map segment within the bounding box. Note the other parameters, [Section 1](01-WCS-basics.ipynb) showed how to obtain them.
With the data on the client side some regular interaction can be started with a library like [rasterIO](https://rasterio.readthedocs.io/). First open the file from disk: