Unlimited learning, half price | 50% off
Get 50% off unlimited learning

loon.ggplot (version 1.0.1)

loon2ggplot: loon to ggplot

Description

Create a ggplot object from a loon widget

Usage

loon2ggplot(target, ...)

# S3 method for default loon2ggplot(target, ...)

# S3 method for l_plot loon2ggplot(target, ...)

# S3 method for l_hist loon2ggplot(target, ...)

# S3 method for l_plot3D loon2ggplot(target, ...)

# S3 method for l_compound loon2ggplot(target, ...)

# S3 method for l_layer_graph loon2ggplot(target, ...)

# S3 method for l_layer_histogram loon2ggplot(target, ...)

# S3 method for l_layer_scatterplot loon2ggplot(target, ...)

# S3 method for l_pairs loon2ggplot(target, ...)

# S3 method for l_serialaxes loon2ggplot(target, ...)

# S3 method for l_ts loon2ggplot(target, ...)

Arguments

target

aloon or a vector that specifies the widget, layer, glyph, navigator or context completely. The widget is specified by the widget path name (e.g. '.l0.plot'), the remaining objects by their ids.

...

arguments used inside loon2ggplot(), not used by this method

Value

a ggplot object

Examples

Run this code
# NOT RUN {
if(interactive()) {
  l <- l_plot(iris, color = iris$Species)
  p <- loon2ggplot(l)
  p # a ggplot object
  str(p)
  # add themes
  p + geom_smooth() + theme_linedraw()
}

# }

Run the code above in your browser using DataLab