Function creates a scatterplot matrix using loon's scatterplot widgets
l_pairs( data, connectedScales = c("cross", "none"), linkingGroup, linkingKey, showItemLabels = TRUE, itemLabel, showHistograms = FALSE, histLocation = c("edge", "diag"), histHeightProp = 1, histArgs = list(), showSerialAxes = FALSE, serialAxesArgs = list(), parent = NULL, plotWidth = 100, plotHeight = 100, span = 10L, showProgressBar = TRUE, ... )
data | a data.frame with numerical data to create the scatterplot matrix |
---|---|
connectedScales | Determines how the scales of the panels are to be connected.
|
linkingGroup | string giving the linkingGroup for all plots. If missing,
a default |
linkingKey | a vector of strings to provide a linking identity for each row of the
|
showItemLabels | TRUE, logical indicating whether its itemLabel pops up over a point when the mouse hovers over it. |
itemLabel | a vector of strings to be used as pop up information when the mouse hovers
over a point. If missing, the default |
showHistograms | logical (default FALSE) to show histograms of each variable or not |
histLocation | one "edge" or "diag", when showHistograms = TRUE |
histHeightProp | a positive number giving the height of the histograms as a proportion of the height of the scatterplots |
histArgs | additional arguments to modify the `l_hist` states |
showSerialAxes | logical (default FALSE) indication of whether to show a serial axes plot in the bottom left of the pairs plot (or not) |
serialAxesArgs | additional arguments to modify the `l_serialaxes` states |
parent | a valid Tk parent widget path. When the parent widget is
specified (i.e. not |
plotWidth | default plot width (in pixel) |
plotHeight | default plot height (in pixel) |
span | How many column/row occupies for each widget |
showProgressBar | Logical; show progress bar or not |
... | named arguments to modify the `l_plot` states of the scatterplots |
an `l_pairs` object (an `l_compound` object), being a list with named elements, each representing a separate interactive plot. The names of the plots should be self explanatory and a list of all plots can be accessed from the `l_pairs` object via `l_getPlots()`. All plots are linked by default (name taken from data set if not provided). Panning and zooming are constrained to work together within the scatterplot matrix (and histograms).
l_plot
and l_getPlots
if(interactive()){ p <- l_pairs(iris[,-5], color=iris$Species, linkingGroup = "iris") p <- l_pairs(iris[,-5], color=iris$Species, linkingGroup = "iris", showHistograms = TRUE, showSerialAxes = TRUE) # plot names names(p) # Each plot must be accessed to make changes not managed through # linking. # E.g. to change the glyph on all scatterplots to open circles for (plot in l_getPlots(p)) { if (is(plot, "l_plot")) { plot["glyph"] <- "ocircle"} } }