The current algorithm is somewhat crude --- selects the region whose
centroid is closest to the click. A more sophisticated approach would
use map.where.
identify(map("state", fill = TRUE, col = 0))
if(require(mapproj))
identify(map("world", proj = "lagrange", fill = TRUE, col = 0, wrap=c(-180,180,-90)))