slw_snapshot {sleepwalk}R Documentation

Make a snapshot of the currently running Sleepwalk app

Description

This function produces a static plot that shows a given state of the currently active Sleepwalk app. Double click on a point in the web browser will generate a command that can reproduce this exact state of the app.

Usage

slw_snapshot(point, emb = 1, returnList = FALSE)

Arguments

point

an index of the focus point (i.e. the one, over which the mouse is hovering at the moment). To learn the index of a point double click on it in the web browser.

emb

an index of the embedding of the focus point. To learn the index of an embedding double click on any of its points in the web browser.

returnList

if TRUE returns a list of ggplot objects (one per embedding), that can be easily modified later. Otherwise returns a single ggplot objects with all the embeddings.

Value

a ggplot object or a list of ggplot objects.

Examples

data("iris")
sleepwalk(iris[, c(1,3)], iris[1:4], pointSize = 4)
slw_snapshot(10)


[Package sleepwalk version 0.3.2 Index]