Description Usage Arguments Value Examples
Compares different statistics across geographical regions
1 2 3 4 5 | l_micromaps(top = tktoplevel(), mm_inspector = TRUE, title = "Micromaps",
map.label = "Map", lab.label = "Labels", spdf, grouping = NULL,
n_groups = NULL, variables, num_optvars = NULL, spacing = c("equal",
"max"), color = NULL, size = 6, linkingKey = NULL,
linkingGroup = NULL, sync = c("pull", "push"), ...)
|
top |
Tk top level window. Defaults to a new window |
mm_inspector |
Whether to draw custom inspector for the display, which allows for variable selection, variable label update, font size adjustment, and setting grouping of points. Defaults to TRUE. Once created, the inspector can only be closed when the main display window is closed |
title |
Title for linked micromaps. Appears in the title bar of the toplevel window |
map.label |
Label for maps (rightmost) panel |
lab.label |
Label for labels (leftmost) panel |
spdf |
|
grouping |
An optional character vector specifying how many points to have per row (from top to bottom of display) |
n_groups |
An optional integer specifying how many rows to have.
If both |
variables |
List specifying variables to plot. Variable required: |
num_optvars |
Number of possible optional variables for |
spacing |
Spacing scheme for points - either 'equal' or 'max'. The 'equal' scheme spaces points out equally, while the 'max' scheme ensures the same amount of spacing between points as the row with the largest number of points |
color |
Color scheme. Defaults to NULL, in which case colors are
generated using |
size |
Size of glyphs for scatterplots and label panel. Defaults to 6 |
linkingKey |
Linking mechanism in |
linkingGroup |
Linking mechanism in |
sync |
Can be either 'pull' or 'push', determines whether the initial synchronization should adapt to the linked states of other linked plots ("pull") or whether it should overwrite the states of the other linked plot with its own linked states ("push") |
... |
Other optional named arguments to modify states of scatterplots |
An object of classes loon_micromaps
and loon
, containing
the Tk toplevel window, linkingGroup
value, linkingKey
values,
and the handles for the loon
plot objects corresponding to
the labels panel, scatterplot panel(s) and map panel in list form
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | ## Not run:
data("USstates", package = "micromap")
data("edPov", package = "micromap")
USstates@data <- merge(USstates@data, edPov, by.x = 'ST', by.y = 'StateAb')
mm <- l_micromaps(lab.label = 'States',
spdf = USstates,
variables = list(id.var = 'ST_NAME',
grouping.var = list(name = 'pov', xlab = 'Percent'),
var2 = list(name = 'ed', xlab = 'Percent')),
spacing = 'max', sync = 'push',
itemLabel = as.character(USstates@data$ST_NAME),
showItemLabels = T)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.