lets_plot.geo_data.geocode_states

lets_plot.geo_data.geocode_states(names=None) lets_plot.geo_data.geocoder.NamesGeocoder

Create a NamesGeocoder object for states. Allows to refine ambiguous request with where() method, with a scope that limits area of geocoding or with parents.

Parameters

names (str or list) – Names of objects to be geocoded.

Returns

Geocoder object specification.

Return type

NamesGeocoder

Examples

1from IPython.display import display
2from lets_plot import *
3from lets_plot.geo_data import *
4LetsPlot.setup_html()
5states = geocode_states().scope('UK').get_boundaries()
6display(states)
7ggplot() + \
8    geom_map(aes(fill='found name'), data=states, color='white') + \
9    ggtitle('UK States')
The geodata is provided by © OpenStreetMap contributors and is made available here under the Open Database License (ODbL).