iplots (version 1.1-7)

imap: Interactive Map

Description

This function creates a new interactive map from the given data.

Usage

imap(x, y=NULL, ...)

Arguments

x

either an object of the class "map" as created by the map function or a vector of the x-coordinates of the map polygons

y

y-coordinates of the map polygons

...

All additional parameters are passed to iplot.opt.

Value

Resulting plot object.

Details

Creates an interactive map plot.

The input can be either an object of the class "map" passed directly to the x parameter or two vectors of matching coordinates passed to x and y. The format for polygons in the same as used by the map function.

Each polygon should correspond to a case and it will be linked correspondingly. See ivar.new.map for details on map variables.

Note: this function is currently experimental and it may change in the future.

See Also

iplot, ivar.new.map

Examples

Run this code
# NOT RUN {
library(maps)
m <- map('state', plot=FALSE)
imap(m)
# }

Run the code above in your browser using DataCamp Workspace