identify.Map: Identify polygons within a plotted map from the maptools packages.
Description
This function allows you to click in a polygon in a map plotted using
the maptools package and labels the polygon.
Usage
identify.Map(x, labels = as.character(Map$att.data$NAME), n = Inf, ...)
identify.polylist(...)
Arguments
x
The map object plotted using plot.Map.
labels
Vector of labels used to label the polygons.
n
Maximum number of polygons to label.
...
Additional arguments passed to identify.Map or text.
Value
A vector of integers corresponding to the polygons clicked on.
Details
The function identify.polylist is just a wrapper function for
identify.Map which handles both types of data.
The point you click on is checked against every polygon in the map, so
this function may be slow on very complicated maps.
Right click on the map to stop before n.