47 |
80 |
81 | ")
82 |
83 | cat(a, file = file)
84 | message("html file written to: ", file)
85 |
86 | return(invisible(file))
87 | }
88 |
--------------------------------------------------------------------------------
/R/output_json.R:
--------------------------------------------------------------------------------
1 | #' Print the JSON of a Bokeh figure
2 | #' @param fig figure to print
3 | #' @param prepare logical - should the figure be sent through preparations that need to be done prior to plotting (TRUE), or printed as-is (FALSE)
4 | #' @param pretty parameter passed on to \code{\link[jsonlite]{toJSON}}
5 | #' @param file parameter passed on to \code{\link[base]{cat}}
6 | #' @param pbcopy logical - if on OSX, should the results be passed to the clipboard (TRUE) instead of printed to the screen (FALSE)?
7 | #' @examples
8 | #' \dontrun{
9 | #' p <- figure() %>% ly_points(1:10) %>%
10 | #' tool_pan(dimensions = "height")
11 | #' print_model_json(p)
12 | #' }
13 | #' @importFrom jsonlite toJSON
14 | #' @export
15 | print_model_json <- function(fig, prepare = TRUE, pretty = TRUE, file = "", pbcopy = FALSE) {
16 | if (prepare) {
17 | fig <- rbokeh_prerender(fig)
18 | }
19 |
20 | if (pbcopy)
21 | file <- pipe("pbcopy")
22 | cat(jsonlite::toJSON(fig$x$docs_json, pretty = pretty,
23 | auto_unbox = TRUE, null = "null", na = "null"), "\n", file = file)
24 | }
25 |
--------------------------------------------------------------------------------
/R/output_prerender.R:
--------------------------------------------------------------------------------
1 | rbokeh_prerender <- function(fig) {
2 |
3 | fig$x$debug <- getOption("rbokeh_debug", FALSE)
4 |
5 | if (fig$x$modeltype %in% c("Plot", "GMapPlot")) {
6 | if (length(fig$x$spec$layers) == 0 && fig$x$spec$model$plot$type != "GMapPlot") {
7 | message("This figure is empty...")
8 | return(NULL)
9 | } else {
10 | fig <- prepare_figure(fig)
11 | }
12 | } else if (fig$x$modeltype == "GridPlot") {
13 | fig <- prepare_gridplot(fig)
14 | } else {
15 | stop("Unsupported model type: ", fig$x$modeltype)
16 | }
17 |
18 | # sapply(fig$x$spec$model, function(x) {
19 | # # x$type
20 | # x$id
21 | # })
22 |
23 | fig$x$docs_json[[1]]$roots$references <- fig$x$spec$model
24 | fig$x$docs_json[[1]]$roots$references <- remove_model_names(fig$x$docs_json[[1]]$roots$references)
25 | fig$x$spec <- NULL
26 | fig$preRenderHook <- NULL # nolint
27 |
28 | # attr(fig$x, "TOJSON_ARGS") <- list(auto_unbox = FALSE)
29 |
30 | ## we need to preserve "NaN" (which is NA in R) for bokeh to render properly
31 | # attr(fig$x, "TOJSON_ARGS") <- list(na = "string")
32 | ## actually this causes problems with categorical and date data
33 | ## so we'll handle it in the js prior to rendering
34 |
35 | fig
36 | }
37 |
--------------------------------------------------------------------------------
/R/output_save.R:
--------------------------------------------------------------------------------
1 | #' Make a static png file for an htmlwidget
2 | #'
3 | #' @param p htmlwidget object
4 | #' @param file where to save png file
5 | #' @param timeout plot render timeout in milliseconds (see details)
6 | #' @details This uses phantomjs (\url{https://phantomjs.org}) to render your htmlwidget in a headless browser and take a screenshot of it, creating a static output. This assumes that phantomjs has been installed on your machine and is available as a system call. For plots that take longer to load and render, you may need to increase the value of \code{timeout}. Note that this function is experimental.
7 | #' @examples
8 | #' \dontrun{
9 | #' path <- tempfile(fileext = ".png")
10 | #' figure(tools = NULL) %>%
11 | #' ly_points(1:10) %>%
12 | #' widget2png(path)
13 | #' }
14 | #' @export
15 | widget2png <- function(p, file, timeout = 500) {
16 | phantom <- find_phantom()
17 | file <- path.expand(file)
18 |
19 | if (phantom == "") {
20 | message(
21 | "** phantomjs dependency could not be found - static plot cannot be generated ",
22 | "(run phantom_install() for details)")
23 | } else {
24 | res <- try({
25 | ff <- tempfile(fileext = ".html")
26 | ffjs <- tempfile(fileext = ".js")
27 |
28 | if (inherits(p, "rbokeh")) {
29 | # don't want any padding
30 | p$sizingPolicy$padding <- 0 # nolint
31 | suppressMessages(rbokeh2html(p, file = ff))
32 | } else if (inherits(p, "htmlwidget")) {
33 | suppressMessages(htmlwidgets::saveWidget(p, file = ff))
34 | }
35 |
36 | js <- paste0("var page = require('webpage').create();
37 | page.open('file://", ff, "', function() {
38 | // $('html').style.zoom = 2;
39 | window.setTimeout(function () {
40 | page.render('", file, "');
41 | phantom.exit();
42 | }, ", timeout, ");
43 | });")
44 | cat(js, file = ffjs)
45 | system2(phantom, ffjs, stdout = TRUE, stderr = TRUE)
46 | })
47 | if (inherits(res, "try-error"))
48 | message("** could not create static plot...")
49 |
50 | # system(paste("open ", ffjs))
51 | # system(paste("open ", dirname(ffjs)))
52 | }
53 | invisible(res)
54 | }
55 |
56 | #' Instructions for installing phantomjs
57 | #' @export
58 | phantom_install <- function() {
59 | message(
60 | "Please visit this page to install phantomjs on your system: ",
61 | "https://phantomjs.org/download.html")
62 | }
63 |
64 | # similar to webshot
65 | find_phantom <- function() {
66 | phantom <- Sys.which("phantomjs")
67 | if (Sys.which("phantomjs") == "") {
68 | if (identical(.Platform$OS.type, "windows")) {
69 | phantom <- Sys.which(file.path(Sys.getenv("APPDATA"), "npm", "phantomjs.cmd"))
70 | }
71 | }
72 | phantom
73 | }
74 |
--------------------------------------------------------------------------------
/R/point_types.R:
--------------------------------------------------------------------------------
1 |
2 | #' Display glyph types available for ly_points()
3 | #' @param size size of the glyph
4 | #' @param color color to use for line and fill properties
5 | #' @param width,height dimensions of output plot
6 | #' @examples
7 | #' point_types()
8 | #' @export
9 | point_types <- function(size = 25, color = "blue", width = 800, height = 450) {
10 |
11 | types <- c(as.list(marker_pch_types), as.list(marker_names))
12 |
13 | f <- figure(ylim = as.character(5:1), width = width, height = height, xlab = NULL, ylab = NULL)
14 | grid <- expand.grid(1:8, 1:5)
15 | for (ii in seq_along(types)) {
16 | cur_grid <- as.character(grid[ii, ])
17 | f <- f %>%
18 | ly_points(cur_grid[1], cur_grid[2],
19 | glyph = types[[ii]], color = color, size = size)
20 | }
21 |
22 | f %>%
23 | ly_text(as.character(grid[, 1]),
24 | paste(as.character(grid[, 2]), ":0.1", sep = ""),
25 | unlist(types), font_size = "12px",
26 | align = "center", baseline = "bottom")
27 | }
28 |
--------------------------------------------------------------------------------
/R/rbokeh-package.R:
--------------------------------------------------------------------------------
1 | #' @importFrom stats aggregate complete.cases is.ts ppoints quantile qunif runif time
2 | #' @importFrom grDevices rgb2hsv hsv boxplot.stats col2rgb contourLines hsv rgb2hsv
3 | #' @importFrom pryr named_dots
4 | #' @importFrom utils head tail
5 | NULL
6 |
7 | #' rbokeh: R interface for Bokeh
8 | #'
9 | #' R interface for creating plots in Bokeh. Bokeh by Continuum Analytics, \url{https://docs.bokeh.org/en/latest/}
10 | #'
11 | #' For full documentation on the package, visit \url{https://hafen.github.io/rbokeh/}
12 | #' @name rbokeh-package
13 | #' @aliases rbokeh
14 | #' @docType package
15 | NULL
16 |
17 | #' "Periodic Table" dataset
18 | #'
19 | #' @name elements
20 | #' @docType data
21 | #' @description
22 | #' Data for periodic table of the elements
23 | #' @usage elements
24 | #' @keywords data
25 | #' @example man-roxygen/ex-elements.R
26 | NULL
27 |
28 | #' Flight frequency dataset
29 | #'
30 | #' @name flightfreq
31 | #' @docType data
32 | #' @description
33 | #' Daily counts of domestic flights in the U.S. from 1999 to mid-2008
34 | #' @usage flightfreq
35 | #' @keywords data
36 | #' @example man-roxygen/ex-flightfreq.R
37 | NULL
38 |
39 | #' Hexagon binned counts of NYC taxi pickup locations
40 | #'
41 | #' @name nyctaxihex
42 | #' @docType data
43 | #' @description
44 | #' Counts of NYC taxi pickups by location for January 2013, obtained from \href{https://chriswhong.com/open-data/foil_nyc_taxi/}{here}.
45 | #' @usage nyctaxihex
46 | #' @keywords data
47 | #' @examples
48 | #' \dontrun{
49 | #' gmap(title = "NYC taxi pickups January 2013",
50 | #' lat = 40.74, lng = -73.95, zoom = 11,
51 | #' map_type = "roadmap", width = 1000, height = 800) %>%
52 | #' ly_hexbin(nyctaxihex, alpha = 0.5,
53 | #' palette = "Spectral10", trans = log, inv = exp)
54 | #' }
55 | NULL
56 |
57 | #' Pipe figures
58 | #'
59 | #' @importFrom magrittr %>%
60 | #' @name %>%
61 | #' @rdname pipe
62 | #' @export
63 | #' @param lhs a Bokeh figure
64 | #' @param rhs a layer to add to the figure
65 | NULL
66 |
--------------------------------------------------------------------------------
/R/shiny.R:
--------------------------------------------------------------------------------
1 | # nolint start
2 | #' Widget output function for use in Shiny
3 | #' @param outputId output variable to read from
4 | #' @param width a valid CSS unit for the width or a number, which will be coerced to a string and have "px" appended.
5 | #' @param height a valid CSS unit for the height or a number, which will be coerced to a string and have "px" appended.
6 | #'
7 | #' @example man-roxygen/ex-shiny.R
8 | #'
9 | #' @export
10 | rbokehOutput <- function(outputId, width = "100%", height = "400px") {
11 | htmlwidgets::shinyWidgetOutput(outputId, "rbokeh", width, height, package = "rbokeh")
12 | }
13 |
14 | #' Widget render function for use in Shiny
15 | #' @param expr an expression that generates a rbokeh figure
16 | #' @param env the environment in which to evaluate expr.
17 | #' @param quoted is expr a quoted expression (with quote())? This is useful if you want to save an expression in a variable.
18 | #'
19 | #' @seealso \code{\link{rbokehOutput}} for an example in Shiny
20 | #'
21 | #' @export
22 | renderRbokeh <- function(expr, env = parent.frame(), quoted = FALSE) {
23 | if (!quoted) expr <- substitute(expr)
24 | htmlwidgets::shinyRenderWidget(expr, rbokehOutput, env, quoted = TRUE)
25 | }
26 | # nolint end
27 |
--------------------------------------------------------------------------------
/R/theme_title.R:
--------------------------------------------------------------------------------
1 | #' Override theme parameters for general plot attributes
2 | #'
3 | #' @param fig figure to modify
4 | #' @param background_fill_color (color) background color of plot
5 | #' @param background_fill_alpha (numeric) background color alpha of plot
6 | #' @param border_fill_color (color) fill color of border area of plot
7 | #' @param border_fill_alpha (numeric) fill color alpha of border area of plot
8 | #' @param align ('left', 'right', 'center') The text align for the plot title.
9 | #' @param text_alpha The text alpha for the plot title.
10 | #' @param text_baseline ('top', 'middle', 'bottom', 'alphabetic', 'hanging') The text baseline for the plot title.
11 | #' @param text_color (color) The text color for the plot title.
12 | #' @param text_font (string) The text font for the plot title.
13 | #' @param text_font_size (string - e.g. '12pt') The text font size for the plot title.
14 | #' @param text_font_style ('normal', 'italic', 'bold') The text font style for the plot title.
15 | #' @param pars optionally specify a named list of all parameters - useful when dealing with theme lists
16 | #' @examples
17 | #' figure(title = "asdf") %>%
18 | #' ly_points(1:10) %>%
19 | #' theme_title(text_color = "red")
20 | #' @export
21 | theme_title <- function(fig,
22 | pars = NULL,
23 | background_fill_color = "white",
24 | background_fill_alpha = 1,
25 | border_fill_color = "white",
26 | border_fill_alpha = 1,
27 | align = "left",
28 | text_alpha = 1,
29 | text_baseline = "bottom",
30 | text_color = "#444444",
31 | text_font = "Helvetica",
32 | text_font_size = "12pt",
33 | text_font_style = "normal"
34 | ) {
35 |
36 | # this will provide a list of all user-specified arguments
37 | # (can ignore the defaults for the ones they don't specify
38 | # because they are defaults if not specified in bokeh)
39 | if (is.null(pars)) {
40 | specified <- names(as.list(match.call())[-1])
41 | pars <- as.list(environment())[specified]
42 | }
43 | pars <- pars[names(pars) %in% names(title_par_validator_map)]
44 |
45 | pars <- handle_extra_pars(pars, title_par_validator_map)
46 | parnames <- names(pars)
47 |
48 | if (!is.null(fig$x$modeltype) && fig$x$modeltype == "GridPlot") {
49 | for (ii in seq_along(fig$x$spec$figs)) {
50 | if (!is.null(fig$x$spec$figs[[ii]]$x$spec$model$title))
51 | for (nm in parnames)
52 | fig$x$spec$figs[[ii]]$x$spec$model$title$attributes[[nm]] <- pars[[nm]]
53 | }
54 | } else {
55 | if (!is.null(fig$x$spec$model$title)) {
56 | for (nm in parnames)
57 | fig$x$spec$model$title$attributes[[nm]] <- pars[[nm]]
58 | } else {
59 | message("Note: there isn't a title to appy a theme to...")
60 | }
61 | }
62 |
63 | fig
64 | }
65 |
66 | title_par_validator_map <- list(
67 | "background_fill_color" = "color",
68 | "background_fill_alpha" = "num_data_spec",
69 | "border_fill_color" = "color",
70 | "border_fill_alpha" = "alpha",
71 | "text_color" = "color",
72 | "text_alpha" = "num_data_spec",
73 | "align" = "align",
74 | "text_baseline" = "text_baseline",
75 | "text_font_style" = "font_style",
76 | "text_font" = "string",
77 | "text_font_size" = "font_size_string"
78 | )
79 |
--------------------------------------------------------------------------------
/R/zzz.R:
--------------------------------------------------------------------------------
1 | .onLoad <- function(libname, pkgname){
2 | options(bokeh_theme = bk_default_theme())
3 | }
4 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | [](https://github.com/hafen/rbokeh/actions)
2 |
3 | [](https://codecov.io/github/hafen/rbokeh?branch=master)
4 | [](https://cran.r-project.org/package=rbokeh)
5 | [](https://cran.r-project.org/package=rbokeh)
6 | # rbokeh

7 |
8 | A native R plotting library that provides a flexible declarative interface for creating interactive web-based graphics, backed by the Bokeh visualization library.
9 |
10 | ### Install
11 |
12 | ```r
13 | # from CRAN:
14 | install.packages("rbokeh")
15 |
16 | # from github:
17 | remotes::install_github("bokeh/rbokeh")
18 | ```
19 |
20 | ### Use
21 |
22 | Please see [here](https://hafen.github.io/rbokeh/articles/rbokeh.html).
23 |
--------------------------------------------------------------------------------
/_pkgdown.yml:
--------------------------------------------------------------------------------
1 | navbar:
2 | structure:
3 | left: [home, intro, reference, news]
4 | right: [github]
5 | components:
6 | articles: ~
7 |
8 | destination: docs
9 |
10 | reference:
11 | - title: "rbokeh"
12 | contents:
13 | - rbokeh-package
14 | - title: "Plots"
15 | contents:
16 | - figure
17 | - gmap
18 | - grid_plot
19 | - title: "Layer Functions"
20 | contents:
21 | - ly_annular_wedge
22 | - ly_annulus
23 | - ly_arc
24 | - ly_bezier
25 | - ly_crect
26 | - ly_image
27 | - ly_image_url
28 | - ly_lines
29 | - ly_multi_line
30 | - ly_oval
31 | - ly_patch
32 | - ly_points
33 | - ly_polygons
34 | - ly_quadratic
35 | - ly_ray
36 | - ly_rect
37 | - ly_segments
38 | - ly_text
39 | - ly_wedge
40 | - title: "Higher-Level Layer Functions"
41 | contents:
42 | - ly_quantile
43 | - ly_density
44 | - ly_hist
45 | - ly_hexbin
46 | - ly_boxplot
47 | - ly_abline
48 | - ly_contour
49 | - ly_curve
50 | - ly_map
51 | - ly_bar
52 | - title: "Higher-Level Layer Functions"
53 | contents:
54 | - x_axis
55 | - x_range
56 | - y_axis
57 | - y_range
58 | - title: "Themes"
59 | contents:
60 | - set_theme
61 | - theme_axis
62 | - theme_grid
63 | - theme_legend
64 | - theme_plot
65 | - theme_title
66 | - set_palette
67 | - bk_default_theme
68 | - pal_color
69 | # -
70 | # file: themes.Rd
71 | # title: "themes"
72 | # -
73 | # file: palettes.Rd
74 | # title: "palettes"
75 | - title: "Interaction Tools"
76 | contents:
77 | - tool_hover
78 | - tool_selection
79 | - tool_tap
80 | - tool_box_select
81 | - tool_box_zoom
82 | - tool_crosshair
83 | - tool_lasso_select
84 | - tool_pan
85 | - tool_reset
86 | - tool_resize
87 | - tool_save
88 | - tool_wheel_zoom
89 | - title: "Callback Interactivity"
90 | contents:
91 | - console_callback
92 | - custom_callback
93 | - debug_callback
94 | - shiny_callback
95 | - title: "Output"
96 | contents:
97 | - print_model_json
98 | - bokeh_render_json
99 | - rbokehOutput
100 | - renderRbokeh
101 | - widget2gist
102 | - widget2png
103 | - rbokeh2html
104 | - title: "Misc"
105 | contents:
106 | - flightfreq
107 | - elements
108 | - nyctaxihex
109 | - catjitter
110 | - get_object_refs
111 | - phantom_install
112 | - "%>%"
113 | - point_types
114 | - gmap_style
115 | - figure_data
116 | - sub_names
117 | - data_name_list
118 | - b_eval
119 |
--------------------------------------------------------------------------------
/cran-comments.md:
--------------------------------------------------------------------------------
1 | ## Submission comments
2 |
3 | Fixed issue that resulted in package being removed from CRAN:
4 |
5 | > This creates and leaves behind a file test.png in /tmp during R CMD check --as-cran, in the \donttest part of the widget2png example (which is run by example()).
6 | >
7 | > This is a serious violation of the CRAN policy.
8 |
9 | ## Test environments
10 |
11 | * local OS X install, R 4.1.0
12 | * win-builder: oldrelease, release, devel
13 | * GitHub Actions - (ubuntu-20.04): release, devel
14 | * GitHub Actions (windows): release
15 | * Github Actions (macOS): release
16 |
17 | ## R CMD check results
18 |
19 | 0 errors | 0 warnings | 0 notes
20 |
--------------------------------------------------------------------------------
/data/elements.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/data/elements.rda
--------------------------------------------------------------------------------
/data/flightFreq.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/data/flightFreq.rda
--------------------------------------------------------------------------------
/data/nyctaxihex.rda:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/data/nyctaxihex.rda
--------------------------------------------------------------------------------
/docs/apple-touch-icon-120x120.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/apple-touch-icon-120x120.png
--------------------------------------------------------------------------------
/docs/apple-touch-icon-152x152.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/apple-touch-icon-152x152.png
--------------------------------------------------------------------------------
/docs/apple-touch-icon-180x180.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/apple-touch-icon-180x180.png
--------------------------------------------------------------------------------
/docs/apple-touch-icon-60x60.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/apple-touch-icon-60x60.png
--------------------------------------------------------------------------------
/docs/apple-touch-icon-76x76.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/apple-touch-icon-76x76.png
--------------------------------------------------------------------------------
/docs/apple-touch-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/apple-touch-icon.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/icons-classic/label.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/icons-classic/label.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/icons-classic/resultset_next.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/icons-classic/resultset_next.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/icons-classic/resultset_previous.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/icons-classic/resultset_previous.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/actions.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/actions.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ajax-loader-small.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ajax-loader-small.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_redo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_redo.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_right_peppermint.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_right_peppermint.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_right_spearmint.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_right_spearmint.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_undo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/arrow_undo.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_blue.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_blue.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_star.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_star.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_toggle_minus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_toggle_minus.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_toggle_plus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/bullet_toggle_plus.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/calendar.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/calendar.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/collapse.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/collapse.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/comment_yellow.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/comment_yellow.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/down.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/down.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/drag-handle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/drag-handle.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/editor-helper-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/editor-helper-bg.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/expand.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/expand.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/header-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/header-bg.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/header-columns-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/header-columns-bg.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/header-columns-over-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/header-columns-over-bg.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/help.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/help.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/info.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/info.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/listview.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/listview.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/pencil.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/pencil.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/row-over-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/row-over-bg.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-asc.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-asc.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-asc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-asc.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-desc.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-desc.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-desc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/sort-desc.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/stripes.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/stripes.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/tag_red.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/tag_red.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/tick.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/tick.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_flat_0_aaaaaa_40x100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_flat_0_aaaaaa_40x100.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_flat_75_ffffff_40x100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_flat_75_ffffff_40x100.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_55_fbf9ee_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_55_fbf9ee_1x400.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_65_ffffff_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_65_ffffff_1x400.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_75_dadada_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_75_dadada_1x400.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_75_e6e6e6_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_75_e6e6e6_1x400.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_95_fef1ec_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_glass_95_fef1ec_1x400.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_highlight-soft_75_cccccc_1x100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-bg_highlight-soft_75_cccccc_1x100.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_222222_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_222222_256x240.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_2e83ff_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_2e83ff_256x240.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_454545_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_454545_256x240.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_888888_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_888888_256x240.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_cd0a0a_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/ui-icons_cd0a0a_256x240.png
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/user_identity.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/user_identity.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/images/user_identity_plus.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/images/user_identity_plus.gif
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/loader.css:
--------------------------------------------------------------------------------
1 | .bk-loader {
2 | margin: auto;
3 | font-size: 10px;
4 | position: relative;
5 | text-indent: -9999em;
6 | border-top: 8px solid rgba(102,102,102, 0.2);
7 | border-right: 8px solid rgba(102,102,102, 0.2);
8 | border-bottom: 8px solid rgba(102,102,102, 0.2);
9 | border-left: 8px solid #666666;
10 | -webkit-transform: translateZ(0);
11 | -ms-transform: translateZ(0);
12 | transform: translateZ(0);
13 | -webkit-animation: bk-load8 1.1s infinite linear;
14 | animation: bk-load8 1.1s infinite linear;
15 | -webkit-transition: opacity 0.7s step-end;
16 | transition: opacity 0.7s step-end;
17 | position: absolute;
18 | }
19 | .bk-loader,
20 | .bk-loader:after {
21 | border-radius: 50%;
22 | width: 70px;
23 | height: 70px;
24 | }
25 | @-webkit-keyframes bk-load8 {
26 | 0% {
27 | -webkit-transform: rotate(0deg);
28 | transform: rotate(0deg);
29 | }
30 | 100% {
31 | -webkit-transform: rotate(360deg);
32 | transform: rotate(360deg);
33 | }
34 | }
35 | @keyframes bk-load8 {
36 | 0% {
37 | -webkit-transform: rotate(0deg);
38 | transform: rotate(0deg);
39 | }
40 | 100% {
41 | -webkit-transform: rotate(360deg);
42 | transform: rotate(360deg);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/notused/bokeh-tables.min.css:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/notused/bokeh-tables.min.css
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/prev/cdn.txt:
--------------------------------------------------------------------------------
1 | ver="1.4.0"
2 | wget http://cdn.pydata.org/bokeh/release/bokeh-$ver.min.css
3 | wget http://cdn.pydata.org/bokeh/release/bokeh-$ver.min.js
4 | wget http://cdn.pydata.org/bokeh/release/bokeh-gl-$ver.min.js
5 | wget http://cdn.pydata.org/bokeh/release/bokeh-tables-$ver.min.css
6 | wget http://cdn.pydata.org/bokeh/release/bokeh-tables-$ver.min.js
7 | wget http://cdn.pydata.org/bokeh/release/bokeh-widgets-$ver.min.css
8 | wget http://cdn.pydata.org/bokeh/release/bokeh-widgets-$ver.min.js
9 | # http://cdn.pydata.org/bokeh/release/bokeh-api-$ver.min.js
10 |
11 |
12 | mv bokeh-$ver.min.css bokeh.min.css
13 | mv bokeh-$ver.min.js bokeh.min.js
14 | mv bokeh-gl-$ver.min.js bokeh-gl.min.js
15 | mv bokeh-tables-$ver.min.css bokeh-tables.min.css
16 | mv bokeh-tables-$ver.min.js bokeh-tables.min.js
17 | mv bokeh-widgets-$ver.min.css bokeh-widgets.min.css
18 | mv bokeh-widgets-$ver.min.js bokeh-widgets.min.js
19 |
20 |
21 | http://cdn.pydata.org/bokeh/release/bokeh-x.y.z.min.js
22 |
23 | # wget http://cdn.pydata.org/bokeh/release/bokeh-$ver.min.css
24 | # mv bokeh-$ver.min.css bokeh.min.css
25 | # wget http://cdn.pydata.org/bokeh/release/bokeh-$ver.min.js
26 | # mv bokeh-$ver.min.js bokeh.min.js
27 | # wget http://cdn.pydata.org/bokeh/release/bokeh-widgets-$ver.min.css
28 | # mv bokeh-widgets-$ver.min.css bokeh-widgets.min.css
29 | # wget http://cdn.pydata.org/bokeh/release/bokeh-widgets-$ver.min.js
30 | # mv bokeh-widgets-$ver.min.js bokeh-widgets.min.js
31 | # wget http://cdn.pydata.org/bokeh/release/bokeh-compiler-$ver.min.js
32 | # mv bokeh-compiler-$ver.min.js bokeh-compiler.min.js
33 |
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/prev/v0.12.1/loader.css:
--------------------------------------------------------------------------------
1 | .bk-loader {
2 | margin: auto;
3 | font-size: 10px;
4 | position: relative;
5 | text-indent: -9999em;
6 | border-top: 8px solid rgba(102,102,102, 0.2);
7 | border-right: 8px solid rgba(102,102,102, 0.2);
8 | border-bottom: 8px solid rgba(102,102,102, 0.2);
9 | border-left: 8px solid #666666;
10 | -webkit-transform: translateZ(0);
11 | -ms-transform: translateZ(0);
12 | transform: translateZ(0);
13 | -webkit-animation: bk-load8 1.1s infinite linear;
14 | animation: bk-load8 1.1s infinite linear;
15 | -webkit-transition: opacity 0.7s step-end;
16 | transition: opacity 0.7s step-end;
17 | position: absolute;
18 | }
19 | .bk-loader,
20 | .bk-loader:after {
21 | border-radius: 50%;
22 | width: 70px;
23 | height: 70px;
24 | }
25 | @-webkit-keyframes bk-load8 {
26 | 0% {
27 | -webkit-transform: rotate(0deg);
28 | transform: rotate(0deg);
29 | }
30 | 100% {
31 | -webkit-transform: rotate(360deg);
32 | transform: rotate(360deg);
33 | }
34 | }
35 | @keyframes bk-load8 {
36 | 0% {
37 | -webkit-transform: rotate(0deg);
38 | transform: rotate(0deg);
39 | }
40 | 100% {
41 | -webkit-transform: rotate(360deg);
42 | transform: rotate(360deg);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/prev/v1.3.4/bokeh-widgets.min.css:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/prev/v1.3.4/bokeh-widgets.min.css
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/bokehjs-0.12.5/prev/v1.3.4/bokeh.min.css:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/articles/rbokeh_files/bokehjs-0.12.5/prev/v1.3.4/bokeh.min.css
--------------------------------------------------------------------------------
/docs/articles/rbokeh_files/rbokeh-binding-0.5.1/rbokeh.js:
--------------------------------------------------------------------------------
1 | HTMLWidgets.widget({
2 | name: 'rbokeh',
3 |
4 | type: 'output',
5 |
6 | initialize: function(el, width, height) {
7 | return {
8 | modelid: '',
9 | elementid: '',
10 | width: width,
11 | height: height
12 | };
13 | },
14 |
15 | renderValue: function(el, x, instance) {
16 |
17 | //clear el for Shiny/dynamic contexts
18 | el.innerHTML = '';
19 |
20 | if(x.isJSON === true) {
21 | x.docs_json = JSON.parse(x.docs_json);
22 | }
23 |
24 | var refkey = Object.keys(x.docs_json)[0];
25 | var refs = x.docs_json[refkey].roots.references;
26 |
27 | instance.modelid = x.modelid;
28 | instance.elementid = x.elementid;
29 |
30 | if(x.debug === true) {
31 | console.log(refs);
32 | console.log(JSON.stringify(refs));
33 | }
34 |
35 | // change 'nulls' in data to NaN
36 | function traverseObject(obj) {
37 | for(var key in obj) {
38 | if(obj[key].constructor === Object) {
39 | traverseObject(obj[key]);
40 | } else if(obj[key].constructor === Array) {
41 | for (var i = 0; i < obj[key].length; i++) {
42 | if(obj[key][i] === null)
43 | obj[key][i] = NaN;
44 | }
45 | }
46 | }
47 | }
48 | for(var i = 0; i < refs.length; i++) {
49 | if(refs[i].type === 'ColumnDataSource')
50 | traverseObject(refs[i].attributes.data);
51 | }
52 |
53 | var dv1 = document.createElement('div');
54 | dv1.setAttribute('class', 'bk-root');
55 | var spinner = document.createElement('div');
56 | spinner.setAttribute('class', 'bk-loader');
57 | spinner.style.opacity = 0;
58 | spinner.style.left = (instance.width / 2 - 35) + 'px';
59 | spinner.style.top = (instance.height / 2 - 35) + 'px';
60 |
61 | var dv = document.createElement('div');
62 | dv.id = x.elementid;
63 | dv.setAttribute('class', 'plotdiv');
64 | dv1.appendChild(dv);
65 | dv1.appendChild(spinner);
66 | el.appendChild(dv1);
67 |
68 | window.getComputedStyle(spinner).opacity;
69 | spinner.style.opacity = 1;
70 |
71 | var render_items = [{
72 | 'docid': x.docid,
73 | 'elementid': x.elementid,
74 | 'modelid': x.modelid
75 | }];
76 |
77 | if(x.debug !== true) {
78 | Bokeh.set_log_level('info');
79 | }
80 |
81 | Bokeh.embed.embed_items(x.docs_json, render_items);
82 |
83 | var timer = function() {
84 | if (dv1.childNodes[0].childNodes.length > 0) {
85 | dv1.removeChild(spinner);
86 | } else {
87 | window.setTimeout(timer, 200);
88 | }
89 | };
90 | timer();
91 |
92 | },
93 |
94 | resize: function(el, width, height, instance) {
95 | }
96 | });
97 |
98 |
--------------------------------------------------------------------------------
/docs/bootstrap-toc.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Bootstrap Table of Contents v0.4.1 (http://afeld.github.io/bootstrap-toc/)
3 | * Copyright 2015 Aidan Feldman
4 | * Licensed under MIT (https://github.com/afeld/bootstrap-toc/blob/gh-pages/LICENSE.md) */
5 |
6 | /* modified from https://github.com/twbs/bootstrap/blob/94b4076dd2efba9af71f0b18d4ee4b163aa9e0dd/docs/assets/css/src/docs.css#L548-L601 */
7 |
8 | /* All levels of nav */
9 | nav[data-toggle='toc'] .nav > li > a {
10 | display: block;
11 | padding: 4px 20px;
12 | font-size: 13px;
13 | font-weight: 500;
14 | color: #767676;
15 | }
16 | nav[data-toggle='toc'] .nav > li > a:hover,
17 | nav[data-toggle='toc'] .nav > li > a:focus {
18 | padding-left: 19px;
19 | color: #563d7c;
20 | text-decoration: none;
21 | background-color: transparent;
22 | border-left: 1px solid #563d7c;
23 | }
24 | nav[data-toggle='toc'] .nav > .active > a,
25 | nav[data-toggle='toc'] .nav > .active:hover > a,
26 | nav[data-toggle='toc'] .nav > .active:focus > a {
27 | padding-left: 18px;
28 | font-weight: bold;
29 | color: #563d7c;
30 | background-color: transparent;
31 | border-left: 2px solid #563d7c;
32 | }
33 |
34 | /* Nav: second level (shown on .active) */
35 | nav[data-toggle='toc'] .nav .nav {
36 | display: none; /* Hide by default, but at >768px, show it */
37 | padding-bottom: 10px;
38 | }
39 | nav[data-toggle='toc'] .nav .nav > li > a {
40 | padding-top: 1px;
41 | padding-bottom: 1px;
42 | padding-left: 30px;
43 | font-size: 12px;
44 | font-weight: normal;
45 | }
46 | nav[data-toggle='toc'] .nav .nav > li > a:hover,
47 | nav[data-toggle='toc'] .nav .nav > li > a:focus {
48 | padding-left: 29px;
49 | }
50 | nav[data-toggle='toc'] .nav .nav > .active > a,
51 | nav[data-toggle='toc'] .nav .nav > .active:hover > a,
52 | nav[data-toggle='toc'] .nav .nav > .active:focus > a {
53 | padding-left: 28px;
54 | font-weight: 500;
55 | }
56 |
57 | /* from https://github.com/twbs/bootstrap/blob/e38f066d8c203c3e032da0ff23cd2d6098ee2dd6/docs/assets/css/src/docs.css#L631-L634 */
58 | nav[data-toggle='toc'] .nav > .active > ul {
59 | display: block;
60 | }
61 |
--------------------------------------------------------------------------------
/docs/docsearch.js:
--------------------------------------------------------------------------------
1 | $(function() {
2 |
3 | // register a handler to move the focus to the search bar
4 | // upon pressing shift + "/" (i.e. "?")
5 | $(document).on('keydown', function(e) {
6 | if (e.shiftKey && e.keyCode == 191) {
7 | e.preventDefault();
8 | $("#search-input").focus();
9 | }
10 | });
11 |
12 | $(document).ready(function() {
13 | // do keyword highlighting
14 | /* modified from https://jsfiddle.net/julmot/bL6bb5oo/ */
15 | var mark = function() {
16 |
17 | var referrer = document.URL ;
18 | var paramKey = "q" ;
19 |
20 | if (referrer.indexOf("?") !== -1) {
21 | var qs = referrer.substr(referrer.indexOf('?') + 1);
22 | var qs_noanchor = qs.split('#')[0];
23 | var qsa = qs_noanchor.split('&');
24 | var keyword = "";
25 |
26 | for (var i = 0; i < qsa.length; i++) {
27 | var currentParam = qsa[i].split('=');
28 |
29 | if (currentParam.length !== 2) {
30 | continue;
31 | }
32 |
33 | if (currentParam[0] == paramKey) {
34 | keyword = decodeURIComponent(currentParam[1].replace(/\+/g, "%20"));
35 | }
36 | }
37 |
38 | if (keyword !== "") {
39 | $(".contents").unmark({
40 | done: function() {
41 | $(".contents").mark(keyword);
42 | }
43 | });
44 | }
45 | }
46 | };
47 |
48 | mark();
49 | });
50 | });
51 |
52 | /* Search term highlighting ------------------------------*/
53 |
54 | function matchedWords(hit) {
55 | var words = [];
56 |
57 | var hierarchy = hit._highlightResult.hierarchy;
58 | // loop to fetch from lvl0, lvl1, etc.
59 | for (var idx in hierarchy) {
60 | words = words.concat(hierarchy[idx].matchedWords);
61 | }
62 |
63 | var content = hit._highlightResult.content;
64 | if (content) {
65 | words = words.concat(content.matchedWords);
66 | }
67 |
68 | // return unique words
69 | var words_uniq = [...new Set(words)];
70 | return words_uniq;
71 | }
72 |
73 | function updateHitURL(hit) {
74 |
75 | var words = matchedWords(hit);
76 | var url = "";
77 |
78 | if (hit.anchor) {
79 | url = hit.url_without_anchor + '?q=' + escape(words.join(" ")) + '#' + hit.anchor;
80 | } else {
81 | url = hit.url + '?q=' + escape(words.join(" "));
82 | }
83 |
84 | return url;
85 | }
86 |
--------------------------------------------------------------------------------
/docs/favicon-16x16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/favicon-16x16.png
--------------------------------------------------------------------------------
/docs/favicon-32x32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/favicon-32x32.png
--------------------------------------------------------------------------------
/docs/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/favicon.ico
--------------------------------------------------------------------------------
/docs/link.svg:
--------------------------------------------------------------------------------
1 |
2 |
3 |
13 |
--------------------------------------------------------------------------------
/docs/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/logo.png
--------------------------------------------------------------------------------
/docs/pkgdown.yml:
--------------------------------------------------------------------------------
1 | pandoc: 2.2.3.2
2 | pkgdown: 1.5.1
3 | pkgdown_sha: ~
4 | articles:
5 | rbokeh-pkg: rbokeh-pkg.html
6 | rbokeh: rbokeh.html
7 | last_built: 2020-05-26T18:41Z
8 |
9 |
--------------------------------------------------------------------------------
/docs/reference/figures/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/docs/reference/figures/logo.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/icons-classic/label.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/icons-classic/label.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/icons-classic/resultset_next.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/icons-classic/resultset_next.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/icons-classic/resultset_previous.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/icons-classic/resultset_previous.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/actions.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/actions.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ajax-loader-small.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ajax-loader-small.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/arrow_redo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/arrow_redo.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/arrow_right_peppermint.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/arrow_right_peppermint.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/arrow_right_spearmint.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/arrow_right_spearmint.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/arrow_undo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/arrow_undo.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/bullet_blue.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/bullet_blue.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/bullet_star.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/bullet_star.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/bullet_toggle_minus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/bullet_toggle_minus.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/bullet_toggle_plus.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/bullet_toggle_plus.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/calendar.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/calendar.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/collapse.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/collapse.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/comment_yellow.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/comment_yellow.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/down.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/down.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/drag-handle.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/drag-handle.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/editor-helper-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/editor-helper-bg.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/expand.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/expand.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/header-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/header-bg.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/header-columns-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/header-columns-bg.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/header-columns-over-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/header-columns-over-bg.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/help.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/help.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/info.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/info.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/listview.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/listview.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/pencil.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/pencil.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/row-over-bg.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/row-over-bg.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/sort-asc.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/sort-asc.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/sort-asc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/sort-asc.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/sort-desc.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/sort-desc.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/sort-desc.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/sort-desc.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/stripes.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/stripes.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/tag_red.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/tag_red.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/tick.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/tick.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_flat_0_aaaaaa_40x100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_flat_0_aaaaaa_40x100.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_flat_75_ffffff_40x100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_flat_75_ffffff_40x100.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_55_fbf9ee_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_55_fbf9ee_1x400.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_65_ffffff_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_65_ffffff_1x400.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_75_dadada_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_75_dadada_1x400.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_75_e6e6e6_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_75_e6e6e6_1x400.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_95_fef1ec_1x400.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_glass_95_fef1ec_1x400.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-bg_highlight-soft_75_cccccc_1x100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-bg_highlight-soft_75_cccccc_1x100.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-icons_222222_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-icons_222222_256x240.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-icons_2e83ff_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-icons_2e83ff_256x240.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-icons_454545_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-icons_454545_256x240.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-icons_888888_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-icons_888888_256x240.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/ui-icons_cd0a0a_256x240.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/ui-icons_cd0a0a_256x240.png
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/user_identity.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/user_identity.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/images/user_identity_plus.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/inst/htmlwidgets/lib/bokehjs/images/user_identity_plus.gif
--------------------------------------------------------------------------------
/inst/htmlwidgets/lib/bokehjs/loader.css:
--------------------------------------------------------------------------------
1 | .bk-loader {
2 | margin: auto;
3 | font-size: 10px;
4 | position: relative;
5 | text-indent: -9999em;
6 | border-top: 8px solid rgba(102,102,102, 0.2);
7 | border-right: 8px solid rgba(102,102,102, 0.2);
8 | border-bottom: 8px solid rgba(102,102,102, 0.2);
9 | border-left: 8px solid #666666;
10 | -webkit-transform: translateZ(0);
11 | -ms-transform: translateZ(0);
12 | transform: translateZ(0);
13 | -webkit-animation: bk-load8 1.1s infinite linear;
14 | animation: bk-load8 1.1s infinite linear;
15 | -webkit-transition: opacity 0.7s step-end;
16 | transition: opacity 0.7s step-end;
17 | position: absolute;
18 | }
19 | .bk-loader,
20 | .bk-loader:after {
21 | border-radius: 50%;
22 | width: 70px;
23 | height: 70px;
24 | }
25 | @-webkit-keyframes bk-load8 {
26 | 0% {
27 | -webkit-transform: rotate(0deg);
28 | transform: rotate(0deg);
29 | }
30 | 100% {
31 | -webkit-transform: rotate(360deg);
32 | transform: rotate(360deg);
33 | }
34 | }
35 | @keyframes bk-load8 {
36 | 0% {
37 | -webkit-transform: rotate(0deg);
38 | transform: rotate(0deg);
39 | }
40 | 100% {
41 | -webkit-transform: rotate(360deg);
42 | transform: rotate(360deg);
43 | }
44 | }
45 |
--------------------------------------------------------------------------------
/inst/htmlwidgets/rbokeh.js:
--------------------------------------------------------------------------------
1 | HTMLWidgets.widget({
2 | name: 'rbokeh',
3 |
4 | type: 'output',
5 |
6 | initialize: function(el, width, height) {
7 | return {
8 | modelid: '',
9 | elementid: '',
10 | width: width,
11 | height: height
12 | };
13 | },
14 |
15 | renderValue: function(el, x, instance) {
16 |
17 | //clear el for Shiny/dynamic contexts
18 | el.innerHTML = '';
19 |
20 | if(x.isJSON === true) {
21 | x.docs_json = JSON.parse(x.docs_json);
22 | }
23 |
24 | var refkey = Object.keys(x.docs_json)[0];
25 | var refs = x.docs_json[refkey].roots.references;
26 |
27 | instance.modelid = x.modelid;
28 | instance.elementid = x.elementid;
29 |
30 | if(x.debug === true) {
31 | console.log(refs);
32 | console.log(JSON.stringify(refs));
33 | }
34 |
35 | // change 'nulls' in data to NaN
36 | function traverseObject(obj) {
37 | for(var key in obj) {
38 | if(obj[key].constructor === Object) {
39 | traverseObject(obj[key]);
40 | } else if(obj[key].constructor === Array) {
41 | for (var i = 0; i < obj[key].length; i++) {
42 | if(obj[key][i] === null)
43 | obj[key][i] = NaN;
44 | }
45 | }
46 | }
47 | }
48 | for(var i = 0; i < refs.length; i++) {
49 | if(refs[i].type === 'ColumnDataSource')
50 | traverseObject(refs[i].attributes.data);
51 | }
52 |
53 | var dv1 = document.createElement('div');
54 | dv1.setAttribute('class', 'bk-root');
55 | var spinner = document.createElement('div');
56 | spinner.setAttribute('class', 'bk-loader');
57 | spinner.style.opacity = 0;
58 | spinner.style.left = (instance.width / 2 - 35) + 'px';
59 | spinner.style.top = (instance.height / 2 - 35) + 'px';
60 |
61 | var dv = document.createElement('div');
62 | dv.id = x.elementid;
63 | dv.setAttribute('class', 'plotdiv');
64 | dv1.appendChild(dv);
65 | dv1.appendChild(spinner);
66 | el.appendChild(dv1);
67 |
68 | window.getComputedStyle(spinner).opacity;
69 | spinner.style.opacity = 1;
70 |
71 | var render_items = [{
72 | 'docid': x.docid,
73 | 'elementid': x.elementid,
74 | 'modelid': x.modelid
75 | }];
76 |
77 | if(x.debug !== true) {
78 | Bokeh.set_log_level('info');
79 | }
80 |
81 | Bokeh.embed.embed_items(x.docs_json, render_items);
82 |
83 | var timer = function() {
84 | if (dv1.childNodes[0].childNodes.length > 0) {
85 | dv1.removeChild(spinner);
86 | } else {
87 | window.setTimeout(timer, 200);
88 | }
89 | };
90 | timer();
91 |
92 | },
93 |
94 | resize: function(el, width, height, instance) {
95 | }
96 | });
97 |
98 |
--------------------------------------------------------------------------------
/inst/htmlwidgets/rbokeh.yaml:
--------------------------------------------------------------------------------
1 | dependencies:
2 | - name: bokehjs
3 | version: 0.12.5
4 | src: htmlwidgets/lib/bokehjs
5 | script:
6 | - bokeh.min.js
7 | # - bokeh-widgets.min.js
8 | stylesheet:
9 | - bokeh.min.css
10 | - loader.css
11 | # - bokeh-widgets.min.css
12 |
--------------------------------------------------------------------------------
/man-roxygen/callback.R:
--------------------------------------------------------------------------------
1 | #' @param callback a callback to be applied to this tool - either a character string of javascript code or any one of \code{\link{debug_callback}}, \code{\link{shiny_callback}}, \code{\link{console_callback}}, \code{\link{custom_callback}}
2 | #' @param ref_layer name of the layer that the callback should be applied to
3 |
--------------------------------------------------------------------------------
/man-roxygen/dots-fillline.R:
--------------------------------------------------------------------------------
1 | #' @param \ldots additional parameters for fine control over fill and line properties (see "Additional parameters" below)
2 | #' @section Additional parameters:
3 | #' \tabular{ll}{
4 | #' \code{fill_color} \tab color to use to fill the glyph with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo' \cr
5 | #' \code{fill_alpha} \tab transparency value between 0 (transparent) and 1 (opaque) \cr
6 | #' \code{line_color} \tab color to use to stroke lines with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo' \cr
7 | #' \code{line_width} \tab stroke width in units of pixels \cr
8 | #' \code{line_alpha} \tab transparency value between 0 (transparent) and 1 (opaque) \cr
9 | #' \code{line_join} \tab how path segments should be joined together 'miter' 'round' 'bevel' \cr
10 | #' \code{line_cap} \tab how path segments should be terminated 'butt' 'round' 'square' \cr
11 | #' \code{line_dash} \tab array of integer pixel distances that describe the on-off pattern of dashing to use \cr
12 | #' \code{line_dash_offset} \tab the distance in pixels into the line_dash that the pattern should start from
13 | #' }
14 |
--------------------------------------------------------------------------------
/man-roxygen/dots-line.R:
--------------------------------------------------------------------------------
1 | #' @param \ldots additional parameters for fine control over line properties (see "Additional parameters" below)
2 | #' @section Additional parameters:
3 | #' \tabular{ll}{
4 | #' \code{line_join} \tab how path segments should be joined together 'miter' 'round' 'bevel' \cr
5 | #' \code{line_cap} \tab how path segments should be terminated 'butt' 'round' 'square' \cr
6 | #' \code{line_dash} \tab an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use \cr
7 | #' \code{line_dash_offset} \tab the distance in pixels into the line_dash that the pattern should start from
8 | #' }
9 |
--------------------------------------------------------------------------------
/man-roxygen/ex-axis.R:
--------------------------------------------------------------------------------
1 | figure() %>%
2 | ly_points(rexp(1000), rexp(1000)) %>%
3 | x_axis(label = "x", log = TRUE) %>%
4 | y_axis(label = "y", log = TRUE)
5 |
6 | figure() %>%
7 | ly_points(2 ^ (1:10)) %>%
8 | y_axis(log = 2)
9 |
10 | # disable scientific tick labels
11 | figure() %>%
12 | ly_points(rnorm(10), rnorm(10) / 1000) %>%
13 | y_axis(use_scientific = FALSE)
14 |
15 | # specify datetime tick labels
16 | # the appropriate datetime units are automatically chosen
17 | big_range <- seq(as.Date("2012-01-01"), as.Date("2012-12-31"), by = "days")
18 | small_range <- seq(as.Date("2012-01-01"), as.Date("2012-02-01"), by = "days")
19 |
20 | figure() %>%
21 | ly_lines(big_range, rnorm(366)) %>%
22 | x_axis(label = "Date", format = list(months = "%b-%Y", days = "%d"))
23 |
24 | figure() %>%
25 | ly_lines(small_range, rnorm(32)) %>%
26 | x_axis(label = "Date", format = list(months = "%b-%Y", days = "%d"))
27 |
28 | # specify numeric tick labels
29 | figure() %>%
30 | ly_points(rnorm(10), rnorm(10) * 10000) %>%
31 | y_axis(number_formatter = "numeral", format = "0,000")
32 |
33 | figure() %>%
34 | ly_points(rnorm(10), rnorm(10) * 100) %>%
35 | y_axis(number_formatter = "printf", format = "%0.1f%%")
36 |
--------------------------------------------------------------------------------
/man-roxygen/ex-bar.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | # count of variety
3 | figure() %>%
4 | ly_bar(variety, data = lattice::barley) %>%
5 | theme_axis("x", major_label_orientation = 90)
6 |
7 | # total yield per variety
8 | figure() %>%
9 | ly_bar(variety, yield, data = lattice::barley, hover = TRUE) %>%
10 | theme_axis("x", major_label_orientation = 90)
11 |
12 | # swap axes and add hover
13 | figure() %>%
14 | ly_bar(yield, variety, data = lattice::barley, hover = TRUE)
15 |
16 | # stack by year
17 | figure() %>%
18 | ly_bar(variety, yield, color = year, data = lattice::barley, hover = TRUE) %>%
19 | theme_axis("x", major_label_orientation = 90)
20 |
21 | # proportional bars
22 | figure() %>%
23 | ly_bar(variety, yield, color = year,
24 | data = lattice::barley, position = "fill", width = 1) %>%
25 | theme_axis("x", major_label_orientation = 90) %>%
26 | set_palette(discrete_color = pal_color(c("red", "blue")))
27 |
28 | # swap axes and use different palette
29 | figure() %>%
30 | ly_bar(yield, variety, color = year,
31 | data = lattice::barley, position = "fill") %>%
32 | set_palette(discrete_color = pal_color(c("red", "blue")))
33 |
34 | # side by side bars
35 | figure() %>%
36 | ly_bar(variety, yield, color = year,
37 | data = lattice::barley, position = "dodge") %>%
38 | theme_axis("x", major_label_orientation = 90)
39 |
40 | # use a different theme
41 | figure() %>%
42 | ly_bar(variety, yield, color = year,
43 | data = lattice::barley, position = "dodge") %>%
44 | theme_axis("x", major_label_orientation = 90)
45 | }
46 |
--------------------------------------------------------------------------------
/man-roxygen/ex-boxplot.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | figure(ylab = "Height (inches)", width = 600) %>%
3 | ly_boxplot(voice.part, height, data = lattice::singer)
4 |
5 | # change orientation of x axis labels
6 | figure(ylab = "Height (inches)", width = 600) %>%
7 | ly_boxplot(voice.part, height, data = lattice::singer) %>%
8 | theme_axis("x", major_label_orientation = 90)
9 | }
10 |
--------------------------------------------------------------------------------
/man-roxygen/ex-elements.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | # prepare data
3 | elements <- subset(elements, !is.na(group))
4 | elements$group <- as.character(elements$group)
5 | elements$period <- as.character(elements$period)
6 |
7 | # add colors for groups
8 | metals <- c("alkali metal", "alkaline earth metal", "halogen",
9 | "metal", "metalloid", "noble gas", "nonmetal", "transition metal")
10 | colors <- c("#a6cee3", "#1f78b4", "#fdbf6f", "#b2df8a", "#33a02c",
11 | "#bbbb88", "#baa2a6", "#e08e79")
12 | elements$color <- colors[match(elements$metal, metals)]
13 | elements$type <- elements$metal
14 |
15 | # make coordinates for labels
16 | elements$symx <- paste(elements$group, ":0.1", sep = "")
17 | elements$numbery <- paste(elements$period, ":0.8", sep = "")
18 | elements$massy <- paste(elements$period, ":0.15", sep = "")
19 | elements$namey <- paste(elements$period, ":0.3", sep = "")
20 |
21 | # create figure
22 | p <- figure(title = "Periodic Table", tools = "",
23 | ylim = as.character(c(7:1)), xlim = as.character(1:18),
24 | xgrid = FALSE, ygrid = FALSE, xlab = "", ylab = "",
25 | height = 600, width = 1200) %>%
26 |
27 | # plot rectangles
28 | ly_crect(group, period, data = elements, 0.9, 0.9,
29 | fill_color = color, line_color = color, fill_alpha = 0.6,
30 | hover = list(name, atomic.number, type, atomic.mass,
31 | electronic.configuration)) %>%
32 |
33 | # add symbol text
34 | ly_text(symx, period, text = symbol, data = elements,
35 | font_style = "bold", font_size = "15pt",
36 | align = "left", baseline = "middle") %>%
37 |
38 | # add atomic number text
39 | ly_text(symx, numbery, text = atomic.number, data = elements,
40 | font_size = "9pt", align = "left", baseline = "middle") %>%
41 |
42 | # add name text
43 | ly_text(symx, namey, text = name, data = elements,
44 | font_size = "6pt", align = "left", baseline = "middle") %>%
45 |
46 | # add atomic mass text
47 | ly_text(symx, massy, text = atomic.mass, data = elements,
48 | font_size = "6pt", align = "left", baseline = "middle")
49 |
50 | p
51 | }
52 |
--------------------------------------------------------------------------------
/man-roxygen/ex-flightfreq.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | p <- figure(width = 1000) %>%
3 | ly_points(date, Freq, data = flightfreq,
4 | hover = list(date, Freq, dow), size = 5) %>%
5 | ly_abline(v = as.Date("2001-09-11"))
6 | p
7 | }
8 |
--------------------------------------------------------------------------------
/man-roxygen/ex-gmap.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | # custom map style
3 | gmap(lat = 40.74, lng = -73.95, zoom = 11,
4 | width = 600, height = 600,
5 | map_style = gmap_style("blue_water"))
6 | }
7 | \dontrun{
8 | gmap(title = "NYC taxi pickups January 2013",
9 | lat = 40.74, lng = -73.95, zoom = 11,
10 | map_type = "roadmap", width = 1000, height = 800) %>%
11 | ly_hexbin(nyctaxihex, alpha = 0.5,
12 | palette = "Spectral10", trans = log, inv = exp)
13 | }
14 |
--------------------------------------------------------------------------------
/man-roxygen/ex-grid.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | idx <- split(1:150, iris$Species)
3 | figs <- lapply(idx, function(x) {
4 | figure(width = 300, height = 300) %>%
5 | ly_points(Sepal.Length, Sepal.Width, data = iris[x, ],
6 | hover = list(Sepal.Length, Sepal.Width))
7 | })
8 |
9 | # 1 row, 3 columns
10 | grid_plot(figs)
11 | # specify xlim and ylim to be applied to all panels
12 | grid_plot(figs, xlim = c(4, 8), ylim = c(1.5, 4.5))
13 | # unnamed list will remove labels
14 | grid_plot(unname(figs))
15 | # 2 rows, 2 columns
16 | grid_plot(figs, nrow = 2)
17 | # x and y axis with same (and linked) limits
18 | grid_plot(figs, same_axes = TRUE)
19 | # x axis with same (and linked) limits
20 | grid_plot(figs, same_axes = c(TRUE, FALSE), nrow = 2)
21 | # x axis with same (and linked) limits and custom xlim
22 | grid_plot(figs, same_axes = c(TRUE, FALSE), xlim = c(5, 7), nrow = 2)
23 | # send lists instead of specifying nrow and ncol
24 | grid_plot(list(
25 | c(list(figs[[1]]), list(figs[[3]])),
26 | c(list(NULL), list(figs[[2]]))
27 | ))
28 | # a null entry will be skipped in the grid
29 | figs2 <- figs
30 | figs2[1] <- list(NULL)
31 | grid_plot(figs2, nrow = 2)
32 | # with themes
33 | grid_plot(figs) %>%
34 | theme_title(text_color = "red") %>%
35 | theme_plot(background_fill_color = "#E6E6E6",
36 | outline_line_color = "white") %>%
37 | theme_grid(c("x", "y"), grid_line_color = "white",
38 | minor_grid_line_color = "white",
39 | minor_grid_line_alpha = 0.4) %>%
40 | theme_axis(c("x", "y"), axis_line_color = "white",
41 | major_label_text_color = "#7F7F7F",
42 | major_tick_line_color = "#7F7F7F",
43 | minor_tick_line_alpha = 0, num_minor_ticks = 2)
44 | # themes again
45 | grid_plot(figs) %>%
46 | set_theme(bk_ggplot_theme)
47 |
48 | # link data across plots in the grid (try box_select tool)
49 | # (data sources must be the same)
50 | tools <- c("pan", "wheel_zoom", "box_zoom", "box_select", "reset")
51 | p1 <- figure(tools = tools, width = 500, height = 500) %>%
52 | ly_points(Sepal.Length, Sepal.Width, data = iris, color = Species)
53 | p2 <- figure(tools = tools, width = 500, height = 500) %>%
54 | ly_points(Petal.Length, Petal.Width, data = iris, color = Species)
55 | grid_plot(list(p1, p2), same_axes = TRUE, link_data = TRUE)
56 | }
57 |
--------------------------------------------------------------------------------
/man-roxygen/ex-hover-callback.R:
--------------------------------------------------------------------------------
1 | library(rbokeh)
2 |
3 | D <- data.frame(
4 | x = c(2, 3, 5, 6, 8, 7),
5 | y = c(6, 4, 3, 8, 7, 5))
6 |
7 | links <- list(
8 | "0" = c(1, 2),
9 | "1" = c(0, 3, 4),
10 | "2" = c(0, 5),
11 | "3" = c(1, 4),
12 | "4" = c(1, 3),
13 | "5" = c(2, 3, 4)
14 | )
15 |
16 | src <- data.frame(
17 | x0 = numeric(0), y0 = numeric(0),
18 | x1 = numeric(0), y1 = numeric(0))
19 |
20 | p <- figure(width = 400, height = 500, toolbar_location = NULL,
21 | title = "Hover Over Points", tools = NULL) %>%
22 | ly_segments(x0 = x0, y0 = y0, x1 = x1, y1 = y1, color = "olive",
23 | alpha = 0.6, line_width = 3, data = src, lname = "segment") %>%
24 | ly_points(x = x, y = y, data = D, color = "olive", size = 30,
25 | alpha = 0.4, lname = "circle")
26 |
27 | callback <- custom_callback(code = sprintf("
28 | var links=%s;
29 | var data = {'x0': [], 'y0': [], 'x1': [], 'y1': []};
30 | var cdata = circle_data.get('data');
31 | var indices = cb_data.index['1d'].indices;
32 | for (i=0; i < indices.length; i++) {
33 | ind0 = indices[i]
34 | for (j=0; j < links[ind0].length; j++) {
35 | ind1 = links[ind0][j];
36 | data['x0'].push(cdata.x[ind0]);
37 | data['y0'].push(cdata.y[ind0]);
38 | data['x1'].push(cdata.x[ind1]);
39 | data['y1'].push(cdata.y[ind1]);
40 | }
41 | }
42 | segment_data.set('data', data);
43 | ", jsonlite::toJSON(links)), lnames = c("circle", "segment"))
44 |
45 | p <- tool_hover(p, callback = callback, c("circle"))
46 | p
47 |
--------------------------------------------------------------------------------
/man-roxygen/ex-hover-custom-callback.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | # hover over the blue points and make the orange points move
3 | figure(title = "hover a blue point") %>%
4 | ly_points(1:10, lname = "blue", lgroup = "g1") %>%
5 | ly_points(2:12, lname = "orange", lgroup = "g1") %>%
6 | tool_hover(custom_callback(
7 | code = "debugger;if(cb_data.index['1d'].indices.length > 0)
8 | orange_data.get('data').x[cb_data.index['1d'].indices] += 0.1
9 | orange_data.trigger('change')", "orange"), "blue")
10 | }
11 |
--------------------------------------------------------------------------------
/man-roxygen/ex-image.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | p <- figure(xlim = c(0, 1), ylim = c(0, 1), title = "Volcano") %>%
3 | ly_image(volcano) %>%
4 | ly_contour(volcano)
5 | p
6 | }
7 |
--------------------------------------------------------------------------------
/man-roxygen/ex-image_url.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | url <- c(" http://bokeh.pydata.org/en/latest/_static/images/logo.png",
3 | "http://developer.r-project.org/Logo/Rlogo-4.png")
4 |
5 | ss <- seq(0, 2*pi, length = 13)[-1]
6 | ws <- runif(12, 2.5, 5) * rep(c(1, 0.8), 6)
7 |
8 | imgdat <- data.frame(
9 | x = sin(ss) * 10, y = cos(ss) * 10,
10 | w = ws, h = ws * rep(c(1, 0.76), 6),
11 | url = rep(url, 6)
12 | )
13 |
14 | p <- figure(xlab = "x", ylab = "y") %>%
15 | ly_image_url(x, y, w = w, h = h, image_url = url, data = imgdat,
16 | anchor = "center") %>%
17 | ly_lines(sin(c(ss, ss[1])) * 10, cos(c(ss, ss[1])) * 10,
18 | width = 15, alpha = 0.1)
19 | p
20 | }
21 |
--------------------------------------------------------------------------------
/man-roxygen/ex-lines.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | z <- lm(dist ~ speed, data = cars)
3 | p <- figure() %>%
4 | ly_points(cars, hover = cars) %>%
5 | ly_lines(lowess(cars), legend = "lowess") %>%
6 | ly_abline(z, type = 2, legend = "lm", width = 2)
7 | p
8 | }
9 |
--------------------------------------------------------------------------------
/man-roxygen/ex-points.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | figure() %>%
3 | ly_points(Sepal.Length, Sepal.Width, data = iris,
4 | color = Species, glyph = Species,
5 | hover = list(Sepal.Length, Sepal.Width))
6 |
7 | # custom hover
8 | mtcars$model <- row.names(mtcars)
9 | figure() %>%
10 | ly_points(disp, mpg, data = mtcars, color = cyl,
11 | hover = "This
@modelhas @hp horsepower!")
12 | }
13 |
--------------------------------------------------------------------------------
/man-roxygen/ex-range.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | # get data from Duluth site in 'barley' data
3 | du <- subset(lattice::barley, site == "Duluth")
4 |
5 | # plot with default ranges
6 | p <- figure(width = 600) %>%
7 | ly_points(yield, variety, color = year, data = du)
8 | p
9 | # y axis is alphabetical
10 |
11 | # manually set x and y axis (y in order of 1932 yield)
12 | p %>%
13 | x_range(c(20, 40)) %>%
14 | y_range(du$variety[order(subset(du, year == 1932)$yield)])
15 | }
16 |
--------------------------------------------------------------------------------
/man-roxygen/ex-selection-callback.R:
--------------------------------------------------------------------------------
1 |
2 |
3 | dat <- data.frame(x = runif(500), y = runif(500))
4 |
5 | p <- figure(title = "select points to adjust mean line",
6 | tools = "lasso_select") %>%
7 | ly_points(x, y, data = dat, lname = "points") %>%
8 | ly_lines(x = c(0, 1), y = rep(mean(dat$y), 2), line_width = 6,
9 | color = "orange", alpha = 0.75, lname = "mean")
10 |
11 | code <- "
12 | var inds = cb_obj.get('selected')['1d'].indices;
13 | var d = cb_obj.get('data');
14 | var ym = 0;
15 |
16 | if (inds.length == 0) { return; }
17 |
18 | for (i = 0; i < inds.length; i++) {
19 | ym += d['y'][inds[i]];
20 | }
21 | ym /= inds.length;
22 |
23 | mean_data.get('data').y = [ym, ym];
24 |
25 | cb_obj.trigger('change');
26 | mean_data.trigger('change');
27 | "
28 |
29 | p %>% tool_lasso_select(custom_callback(code, "mean"), "points")
30 |
--------------------------------------------------------------------------------
/man-roxygen/ex-shapes.R:
--------------------------------------------------------------------------------
1 | theta <- seq(0, 4 * pi, length = 40)
2 | r <- seq(0.5, 10, length = 40)
3 |
4 | d <- data.frame(
5 | x1 = r * cos(theta),
6 | y1 = r * sin(theta),
7 | x2 = 2 * r * cos(theta),
8 | y2 = 2 * r * sin(theta))
9 |
10 | figure() %>% ly_rect(x1, y1, x2, y2, data = d)
11 |
--------------------------------------------------------------------------------
/man-roxygen/ex-shiny.R:
--------------------------------------------------------------------------------
1 | \dontrun{
2 | library("shiny")
3 | library("rbokeh")
4 |
5 | ui <- fluidPage(
6 | rbokehOutput("rbokeh")
7 | )
8 |
9 | server <- function(input, output, session) {
10 | output$rbokeh <- renderRbokeh({
11 | # Use invalidateLater() and jitter() to add some motion
12 | invalidateLater(1000, session)
13 | figure() %>%
14 | ly_points(jitter(cars$speed), jitter(cars$dist))
15 | })
16 | }
17 |
18 | shinyApp(ui, server)
19 |
20 |
21 | library("shiny")
22 | library("rbokeh")
23 |
24 | ui <- fluidPage(
25 | rbokehOutput("rbokeh", width = 500, height = 540),
26 | textOutput("x_range_text")
27 | )
28 |
29 | server <- function(input, output, session) {
30 | output$rbokeh <- renderRbokeh({
31 | figure() %>% ly_points(1:10) %>%
32 | x_range(callback = shiny_callback("x_range"))
33 | })
34 |
35 | output$x_range_text <- reactive({
36 | xrng <- input$x_range
37 | if(!is.null(xrng)) {
38 | paste0("factors: ", xrng$factors, ", start: ", xrng$start,
39 | ", end: ", xrng$end)
40 | } else {
41 | "waiting for axis event..."
42 | }
43 | })
44 | }
45 |
46 | shinyApp(ui, server)
47 | }
48 |
--------------------------------------------------------------------------------
/man-roxygen/ex-tap-debug-callback.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | figure() %>%
3 | ly_points(1:10, lname = "points") %>%
4 | tool_tap(debug_callback("points"), "points")
5 | }
6 |
--------------------------------------------------------------------------------
/man-roxygen/ex-theme.R:
--------------------------------------------------------------------------------
1 | \donttest{
2 | # manually specify a ggplot-like grid and background
3 | figure() %>%
4 | ly_points(1:10) %>%
5 | theme_plot(background_fill_color = "#E6E6E6",
6 | outline_line_color = "white") %>%
7 | theme_grid(c("x", "y"), grid_line_color = "white",
8 | minor_grid_line_color = "white",
9 | minor_grid_line_alpha = 0.4) %>%
10 | theme_axis(c("x", "y"), axis_line_color = "white",
11 | major_label_text_color = "#7F7F7F",
12 | major_tick_line_color = "#7F7F7F",
13 | minor_tick_line_alpha = 0, num_minor_ticks = 2)
14 |
15 | # or use the built in ggplot theme (under development)
16 | figure(data = iris, legend = "top_left", tools = NULL) %>%
17 | ly_points(Sepal.Length, Petal.Length, color = Species) %>%
18 | set_theme(bk_ggplot_theme)
19 | }
20 | \dontrun{
21 | # or to set the theme for all future plots
22 | options(bokeh_theme = bk_ggplot_theme)
23 |
24 | figure() %>%
25 | ly_points(1:10)
26 |
27 | figure() %>%
28 | ly_boxplot(1:10)
29 | }
30 |
--------------------------------------------------------------------------------
/man-roxygen/par-coloralpha.R:
--------------------------------------------------------------------------------
1 | #' @param color color for the glyph - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo' - for glyphs with both fill and line properties, see "Handling color" below
2 | #' @param alpha the alpha transparency of the glyph between 0 (transparent) and 1 (opaque) - if glyph has both fill and color properties, see "Handling alpha" below
3 | #' @section Handling color: The \code{color} parameter is a high-level plot attribute that provides default behavior for coloring glyphs.
4 | #' \itemize{
5 | #' \item When using a glyph that only has line properties, this will be the color of the line.
6 | #' \item When using a glyph that has has line and fill properties, this will be the color of the line and the fill, with the alpha level of the fill reduced by 50\%.
7 | #' \item If full control over fill and line color is desired, the \code{fill_color} and \code{line_color} attributes can be specified explicitly and will override \code{color}.
8 | #' }
9 | #' When color is \code{NULL} and \code{fill_color} or \code{line_color} are not specified, the color will be chosen from the theme.
10 | #' @section Handling alpha: The \code{alpha} is a high-level plot attribute that sets the transparency of the glyph being plotted.
11 | #' \itemize{
12 | #' \item When using a glyph that only has line properties, this will be the alpha of the line.
13 | #' \item When using a glyph that has has line and fill properties, this will be the alpha of the line and the alpha of the fill will be set to 50\% of this value.
14 | #' \item Individual fill and line alpha can be specified with \code{fill_alpha} and \code{line_alpha} and will override \code{alpha}.
15 | #' }
16 |
--------------------------------------------------------------------------------
/man-roxygen/par-hover.R:
--------------------------------------------------------------------------------
1 | #' @param hover a data frame of variables to be displayed when hovering over the glyph or a vector of variable names that can be found and extracted from the \code{data} argument
2 |
--------------------------------------------------------------------------------
/man-roxygen/par-legend.R:
--------------------------------------------------------------------------------
1 | #' @param legend either a logical specifying not to plot a legend for this layer (FALSE) or a string indicating the name of the legend entry for this layer (note that when mapping plot attributes to variables in \code{data}, a legend is automatically created and does not need to be specified - see "Mapped plot attributes and legends" below)
2 | #' @section Mapped plot attributes and legends: When specifying an input data frame for a layer through the \code{data} argument, columns of \code{data} can be used to specify various plot attributes such as \code{color}, etc. For example, with \code{ly_points(..., data = iris, color = Species)}, the \code{Species} variable is used to determine how to color the points. Here, \code{Species} is "mapped" to the \code{color} attribute. Both continuous and categorical variables can be mapped. In the case of continuous variables, the range is cut into slices and attributes are applied to each interval. The mapping from the values of the variable to the actual plot attributes is determined based on the theme.
3 |
--------------------------------------------------------------------------------
/man-roxygen/par-lineprops.R:
--------------------------------------------------------------------------------
1 |
2 | #' @param color color to use to stroke lines with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo'
3 | #' @param alpha transparency value for the line between 0 (transparent) and 1 (opaque)
4 | #' @param width stroke width in units of pixels
5 | #' @param type an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use
6 |
--------------------------------------------------------------------------------
/man-roxygen/par-lnamegroup.R:
--------------------------------------------------------------------------------
1 | #' @param lname layer name
2 | #' @param lgroup layer group
3 |
--------------------------------------------------------------------------------
/man-roxygen/par-text.R:
--------------------------------------------------------------------------------
1 | #' @param text_font font name, e.g., 'times', 'helvetica'
2 | #' @param text_font_size font size in px, em, or pt, e.g., '12pt', '1.5em'
3 | #' @param text_font_style 'normal' 'italic' 'bold'
4 | #' @param text_color color to use to render text with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo'
5 | #' @param text_alpha transparency value between 0 (transparent) and 1 (opaque)
6 | #' @param text_align horizontal anchor point for text 'left' 'right' 'center'
7 | #' @param text_baseline - vertical anchor point for text 'top' 'middle' 'bottom' 'alphabetic' 'hanging'
8 |
--------------------------------------------------------------------------------
/man-roxygen/par-url.R:
--------------------------------------------------------------------------------
1 | #' @param url a string of URLs or a single string that references a variable name (via @@var_name) that can be found and extracted from the \code{data} argument
2 |
--------------------------------------------------------------------------------
/man-roxygen/tools.R:
--------------------------------------------------------------------------------
1 | #' @param fig figure to modify
2 | #' @family tools
3 | #' @note Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
4 |
--------------------------------------------------------------------------------
/man/b_eval.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer__utils.R
3 | \name{b_eval}
4 | \alias{b_eval}
5 | \title{Eval lazy symbol}
6 | \usage{
7 | b_eval(data)
8 | }
9 | \arguments{
10 | \item{data}{data set to be used for evaluation. May be \code{NULL}}
11 | }
12 | \value{
13 | a function that takes in one lazy argument to be evaluated
14 | }
15 | \description{
16 | Evaluate the argument from the env it came from, or from within the data. The arg supplied to the returned function must be lazy.
17 | }
18 |
--------------------------------------------------------------------------------
/man/bokeh_render_json.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/bokeh_render_json.R
3 | \name{bokeh_render_json}
4 | \alias{bokeh_render_json}
5 | \title{Plot a Bokeh JSON specification}
6 | \usage{
7 | bokeh_render_json(json_file)
8 | }
9 | \arguments{
10 | \item{json_file}{path to json file}
11 | }
12 | \description{
13 | Take a path to a Bokeh JSON plot specification file and render it in the browser.
14 | }
15 | \note{
16 | This is mainly useful for development / debugging purposes for reading in json created from another platform like Python, or to be used with tweaking json output from \code{\link{print_model_json}}.
17 | }
18 | \seealso{
19 | \code{\link{print_model_json}}
20 | }
21 |
--------------------------------------------------------------------------------
/man/catjitter.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/misc.R
3 | \name{catjitter}
4 | \alias{catjitter}
5 | \title{Add a small amount of (rbokeh-compatible) noise to a character vector}
6 | \usage{
7 | catjitter(x, factor = 0.5)
8 | }
9 | \arguments{
10 | \item{x}{numeric vector to which jitter should be added}
11 |
12 | \item{factor}{a factor between 0 and 1 that}
13 | }
14 | \description{
15 | Add a small amount of (rbokeh-compatible) noise to a character vector
16 | }
17 | \examples{
18 | figure(data = lattice::singer) \%>\%
19 | ly_points(catjitter(voice.part), jitter(height), color = "black") \%>\%
20 | ly_boxplot(voice.part, height, with_outliers = FALSE)
21 | }
22 |
--------------------------------------------------------------------------------
/man/console_callback.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_callback.R
3 | \name{console_callback}
4 | \alias{console_callback}
5 | \title{Specify a console callback}
6 | \usage{
7 | console_callback()
8 | }
9 | \description{
10 | This registers a callback that simply prints the callback objects in the javascript console of your web browser. A probalby more useful callback is the \code{\link{debug_callback}} which will place you inside a debugger in your web browser allowing you to inspect the callback objects.
11 | }
12 | \examples{
13 | \donttest{
14 | figure() \%>\%
15 | ly_points(1:10) \%>\%
16 | x_range(callback = console_callback()) \%>\%
17 | y_range(callback = console_callback())
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/man/custom_callback.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_callback.R
3 | \name{custom_callback}
4 | \alias{custom_callback}
5 | \title{Specify a custom callback}
6 | \usage{
7 | custom_callback(code, lnames = NULL, args = NULL)
8 | }
9 | \arguments{
10 | \item{code}{a string of javascript callback code}
11 |
12 | \item{lnames}{vector of layer names to be made available inside the callback in addition to the default callback objects (see details)}
13 |
14 | \item{args}{named list of additional references to objects to be addressable in the callback}
15 | }
16 | \description{
17 | This registers a callback that allows you to specify your own custom callback javascript code. A probalby more useful callback to use in conjunction with this for working on the javascript code is the \code{\link{debug_callback}} which will place you inside a debugger in your web browser allowing you to inspect the callback objects.
18 | }
19 | \details{
20 | If we add a layer and provide it, for example the \code{lname} "points", then if we refer to it using the \code{lnames} parameter to the callback, several objects will be made available inside the callback for you to access, given the names "points_data", "points_glyph", "points_glyph_rend", "points_hov_glyph", "points_ns_glyph", all pointers to different objects associated with the "points" layer that your callback can manipulate.
21 | }
22 | \examples{
23 | \donttest{
24 | # hover over the blue points and make the orange points move
25 | figure(title = "hover a blue point") \%>\%
26 | ly_points(1:10, lname = "blue", lgroup = "g1") \%>\%
27 | ly_points(2:12, lname = "orange", lgroup = "g1") \%>\%
28 | tool_hover(custom_callback(
29 | code = "debugger;if(cb_data.index['1d'].indices.length > 0)
30 | orange_data.get('data').x[cb_data.index['1d'].indices] += 0.1
31 | orange_data.trigger('change')", "orange"), "blue")
32 | }
33 | }
34 |
--------------------------------------------------------------------------------
/man/data_name_list.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer__utils.R
3 | \name{data_name_list}
4 | \alias{data_name_list}
5 | \title{List of all types of data name structures that could appear}
6 | \usage{
7 | data_name_list()
8 | }
9 | \description{
10 | List of all types of data name structures that could appear
11 | }
12 |
--------------------------------------------------------------------------------
/man/debug_callback.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_callback.R
3 | \name{debug_callback}
4 | \alias{debug_callback}
5 | \title{Specify a "debug" callback}
6 | \usage{
7 | debug_callback(lnames = NULL, args = NULL)
8 | }
9 | \arguments{
10 | \item{lnames}{vector of layer names to be made available inside the callback in addition to the default callback objects (see \code{\link{custom_callback}} for details)}
11 |
12 | \item{args}{named list of additional references to objects to be addressable in the callback}
13 | }
14 | \description{
15 | This registers a callback that simply places you inside a debugger in your web browser allowing you to inspect the callback objects.
16 | }
17 | \examples{
18 | \donttest{
19 | figure() \%>\%
20 | ly_points(1:10, lname = "points") \%>\%
21 | tool_tap(debug_callback("points"), "points")
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/man/elements.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/rbokeh-package.R
3 | \docType{data}
4 | \name{elements}
5 | \alias{elements}
6 | \title{"Periodic Table" dataset}
7 | \usage{
8 | elements
9 | }
10 | \description{
11 | Data for periodic table of the elements
12 | }
13 | \examples{
14 | \donttest{
15 | # prepare data
16 | elements <- subset(elements, !is.na(group))
17 | elements$group <- as.character(elements$group)
18 | elements$period <- as.character(elements$period)
19 |
20 | # add colors for groups
21 | metals <- c("alkali metal", "alkaline earth metal", "halogen",
22 | "metal", "metalloid", "noble gas", "nonmetal", "transition metal")
23 | colors <- c("#a6cee3", "#1f78b4", "#fdbf6f", "#b2df8a", "#33a02c",
24 | "#bbbb88", "#baa2a6", "#e08e79")
25 | elements$color <- colors[match(elements$metal, metals)]
26 | elements$type <- elements$metal
27 |
28 | # make coordinates for labels
29 | elements$symx <- paste(elements$group, ":0.1", sep = "")
30 | elements$numbery <- paste(elements$period, ":0.8", sep = "")
31 | elements$massy <- paste(elements$period, ":0.15", sep = "")
32 | elements$namey <- paste(elements$period, ":0.3", sep = "")
33 |
34 | # create figure
35 | p <- figure(title = "Periodic Table", tools = "",
36 | ylim = as.character(c(7:1)), xlim = as.character(1:18),
37 | xgrid = FALSE, ygrid = FALSE, xlab = "", ylab = "",
38 | height = 600, width = 1200) \%>\%
39 |
40 | # plot rectangles
41 | ly_crect(group, period, data = elements, 0.9, 0.9,
42 | fill_color = color, line_color = color, fill_alpha = 0.6,
43 | hover = list(name, atomic.number, type, atomic.mass,
44 | electronic.configuration)) \%>\%
45 |
46 | # add symbol text
47 | ly_text(symx, period, text = symbol, data = elements,
48 | font_style = "bold", font_size = "15pt",
49 | align = "left", baseline = "middle") \%>\%
50 |
51 | # add atomic number text
52 | ly_text(symx, numbery, text = atomic.number, data = elements,
53 | font_size = "9pt", align = "left", baseline = "middle") \%>\%
54 |
55 | # add name text
56 | ly_text(symx, namey, text = name, data = elements,
57 | font_size = "6pt", align = "left", baseline = "middle") \%>\%
58 |
59 | # add atomic mass text
60 | ly_text(symx, massy, text = atomic.mass, data = elements,
61 | font_size = "6pt", align = "left", baseline = "middle")
62 |
63 | p
64 | }
65 | }
66 | \keyword{data}
67 |
--------------------------------------------------------------------------------
/man/figure_data.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/figure.R
3 | \name{figure_data}
4 | \alias{figure_data}
5 | \title{Retrieve rbokeh figure data}
6 | \usage{
7 | figure_data(fig)
8 | }
9 | \arguments{
10 | \item{fig}{rbokeh figure}
11 | }
12 | \description{
13 | Retrieve rbokeh figure data
14 | }
15 |
--------------------------------------------------------------------------------
/man/figures/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/man/figures/logo.png
--------------------------------------------------------------------------------
/man/flightfreq.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/rbokeh-package.R
3 | \docType{data}
4 | \name{flightfreq}
5 | \alias{flightfreq}
6 | \title{Flight frequency dataset}
7 | \usage{
8 | flightfreq
9 | }
10 | \description{
11 | Daily counts of domestic flights in the U.S. from 1999 to mid-2008
12 | }
13 | \examples{
14 | \donttest{
15 | p <- figure(width = 1000) \%>\%
16 | ly_points(date, Freq, data = flightfreq,
17 | hover = list(date, Freq, dow), size = 5) \%>\%
18 | ly_abline(v = as.Date("2001-09-11"))
19 | p
20 | }
21 | }
22 | \keyword{data}
23 |
--------------------------------------------------------------------------------
/man/get_object_refs.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/misc.R
3 | \name{get_object_refs}
4 | \alias{get_object_refs}
5 | \title{Get object ids and types from a figure}
6 | \usage{
7 | get_object_refs(fig)
8 | }
9 | \arguments{
10 | \item{fig}{a figure object}
11 | }
12 | \description{
13 | Get object ids and types from a figure
14 | }
15 |
--------------------------------------------------------------------------------
/man/gmap_style.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_gmap.R
3 | \name{gmap_style}
4 | \alias{gmap_style}
5 | \title{Get a Google Map Style}
6 | \usage{
7 | gmap_style(name)
8 | }
9 | \arguments{
10 | \item{name}{name of map style to retrieve (see details)}
11 | }
12 | \description{
13 | Get a Google Map Style
14 | }
15 | \details{
16 | This function provides Google Maps themes that can be passed to the \code{map_style} argument of \code{\link{gmap}}. Currently the most popular styles from \url{https://snazzymaps.com} are available. You can also visit this site or others to specify a custom \code{map_style}. Available styles are: "subtle_grayscale", "shades_of_grey", "blue_water", "pale_dawn", "blue_essence", "apple_mapsesque", "midnight_commander", "light_monochrome", "paper", "retro", "flat_map", "cool_grey".
17 | }
18 | \examples{
19 | \donttest{
20 | # custom map style
21 | gmap(lat = 40.74, lng = -73.95, zoom = 11,
22 | width = 600, height = 600,
23 | map_style = gmap_style("blue_water"))
24 | }
25 | \dontrun{
26 | gmap(title = "NYC taxi pickups January 2013",
27 | lat = 40.74, lng = -73.95, zoom = 11,
28 | map_type = "roadmap", width = 1000, height = 800) \%>\%
29 | ly_hexbin(nyctaxihex, alpha = 0.5,
30 | palette = "Spectral10", trans = log, inv = exp)
31 | }
32 | }
33 | \seealso{
34 | \code{\link{gmap}}
35 | }
36 |
--------------------------------------------------------------------------------
/man/ly_contour.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer_lines.R
3 | \name{ly_contour}
4 | \alias{ly_contour}
5 | \title{Add a "contour" layer to a Bokeh figure}
6 | \usage{
7 | ly_contour(
8 | fig,
9 | z,
10 | x = seq(0, 1, length.out = nrow(z)),
11 | y = seq(0, 1, length.out = ncol(z)),
12 | nlevels = 10,
13 | levels = pretty(range(z, na.rm = TRUE), nlevels),
14 | color = "black",
15 | alpha = 1,
16 | width = 1,
17 | type = 1,
18 | lname = NULL,
19 | lgroup = NULL,
20 | ...
21 | )
22 | }
23 | \arguments{
24 | \item{fig}{figure to modify}
25 |
26 | \item{z}{a matrix containing the values to compute contour lines for}
27 |
28 | \item{x, y}{locations of grid lines at which the values in \code{image} are measured (see \code{\link[grDevices]{contourLines}})}
29 |
30 | \item{nlevels, levels}{parameters sent to \code{\link[grDevices]{contourLines}})}
31 |
32 | \item{color}{color to use to stroke lines with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo'}
33 |
34 | \item{alpha}{transparency value for the line between 0 (transparent) and 1 (opaque)}
35 |
36 | \item{width}{stroke width in units of pixels}
37 |
38 | \item{type}{an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use}
39 |
40 | \item{lname}{layer name}
41 |
42 | \item{lgroup}{layer group}
43 |
44 | \item{\ldots}{additional parameters for fine control over line properties (see "Additional parameters" below)}
45 | }
46 | \description{
47 | Computes and draws contour lines.
48 | }
49 | \section{Additional parameters}{
50 |
51 | \tabular{ll}{
52 | \code{line_join} \tab how path segments should be joined together 'miter' 'round' 'bevel' \cr
53 | \code{line_cap} \tab how path segments should be terminated 'butt' 'round' 'square' \cr
54 | \code{line_dash} \tab an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use \cr
55 | \code{line_dash_offset} \tab the distance in pixels into the line_dash that the pattern should start from
56 | }
57 | }
58 |
59 | \examples{
60 | \donttest{
61 | p <- figure(xlim = c(0, 1), ylim = c(0, 1), title = "Volcano") \%>\%
62 | ly_image(volcano) \%>\%
63 | ly_contour(volcano)
64 | p
65 | }
66 | }
67 | \seealso{
68 | Other layer functions:
69 | \code{\link{ly_abline}()},
70 | \code{\link{ly_annular_wedge}()},
71 | \code{\link{ly_annulus}()},
72 | \code{\link{ly_arc}()},
73 | \code{\link{ly_bar}()},
74 | \code{\link{ly_bezier}()},
75 | \code{\link{ly_boxplot}()},
76 | \code{\link{ly_crect}()},
77 | \code{\link{ly_curve}()},
78 | \code{\link{ly_density}()},
79 | \code{\link{ly_hist}()},
80 | \code{\link{ly_image_url}()},
81 | \code{\link{ly_image}()},
82 | \code{\link{ly_lines}()},
83 | \code{\link{ly_map}()},
84 | \code{\link{ly_multi_line}()},
85 | \code{\link{ly_oval}()},
86 | \code{\link{ly_patch}()},
87 | \code{\link{ly_points}()},
88 | \code{\link{ly_polygons}()},
89 | \code{\link{ly_quadratic}()},
90 | \code{\link{ly_quantile}()},
91 | \code{\link{ly_ray}()},
92 | \code{\link{ly_rect}()},
93 | \code{\link{ly_segments}()},
94 | \code{\link{ly_text}()},
95 | \code{\link{ly_wedge}()}
96 | }
97 | \concept{layer functions}
98 |
--------------------------------------------------------------------------------
/man/ly_density.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer_stats.R
3 | \name{ly_density}
4 | \alias{ly_density}
5 | \title{Add a "density" layer to a Bokeh figure}
6 | \usage{
7 | ly_density(
8 | fig,
9 | x,
10 | data = figure_data(fig),
11 | bw = "nrd0",
12 | adjust = 1,
13 | kernel = c("gaussian", "epanechnikov", "rectangular", "triangular", "biweight",
14 | "cosine", "optcosine"),
15 | weights = NULL,
16 | window = kernel,
17 | n = 512,
18 | cut = 3,
19 | na.rm = FALSE,
20 | color = "black",
21 | alpha = 1,
22 | width = 1,
23 | type = 1,
24 | legend = NULL,
25 | lname = NULL,
26 | lgroup = NULL,
27 | ...
28 | )
29 | }
30 | \arguments{
31 | \item{fig}{figure to modify}
32 |
33 | \item{x, bw, adjust, kernel, weights, window, n, cut, na.rm}{parameters passed to \code{\link[stats]{density}}}
34 |
35 | \item{data}{an optional data frame, providing the source for x}
36 |
37 | \item{color}{color to use to stroke lines with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo'}
38 |
39 | \item{alpha}{transparency value for the line between 0 (transparent) and 1 (opaque)}
40 |
41 | \item{width}{stroke width in units of pixels}
42 |
43 | \item{type}{an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use}
44 |
45 | \item{legend}{text to display in the legend entry for the density line}
46 |
47 | \item{lname}{layer name}
48 |
49 | \item{lgroup}{layer group}
50 |
51 | \item{\ldots}{additional parameters for fine control over line properties (see "Additional parameters" below)}
52 | }
53 | \description{
54 | Draws a kernel density estimate
55 | }
56 | \section{Additional parameters}{
57 |
58 | \tabular{ll}{
59 | \code{line_join} \tab how path segments should be joined together 'miter' 'round' 'bevel' \cr
60 | \code{line_cap} \tab how path segments should be terminated 'butt' 'round' 'square' \cr
61 | \code{line_dash} \tab an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use \cr
62 | \code{line_dash_offset} \tab the distance in pixels into the line_dash that the pattern should start from
63 | }
64 | }
65 |
66 | \examples{
67 | h <- figure(width = 600, height = 400) \%>\%
68 | ly_hist(eruptions, data = faithful, breaks = 40, freq = FALSE) \%>\%
69 | ly_density(eruptions, data = faithful)
70 | h
71 | }
72 | \seealso{
73 | Other layer functions:
74 | \code{\link{ly_abline}()},
75 | \code{\link{ly_annular_wedge}()},
76 | \code{\link{ly_annulus}()},
77 | \code{\link{ly_arc}()},
78 | \code{\link{ly_bar}()},
79 | \code{\link{ly_bezier}()},
80 | \code{\link{ly_boxplot}()},
81 | \code{\link{ly_contour}()},
82 | \code{\link{ly_crect}()},
83 | \code{\link{ly_curve}()},
84 | \code{\link{ly_hist}()},
85 | \code{\link{ly_image_url}()},
86 | \code{\link{ly_image}()},
87 | \code{\link{ly_lines}()},
88 | \code{\link{ly_map}()},
89 | \code{\link{ly_multi_line}()},
90 | \code{\link{ly_oval}()},
91 | \code{\link{ly_patch}()},
92 | \code{\link{ly_points}()},
93 | \code{\link{ly_polygons}()},
94 | \code{\link{ly_quadratic}()},
95 | \code{\link{ly_quantile}()},
96 | \code{\link{ly_ray}()},
97 | \code{\link{ly_rect}()},
98 | \code{\link{ly_segments}()},
99 | \code{\link{ly_text}()},
100 | \code{\link{ly_wedge}()}
101 | }
102 | \concept{layer functions}
103 |
--------------------------------------------------------------------------------
/man/ly_hexbin.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer_hexbin.R
3 | \name{ly_hexbin}
4 | \alias{ly_hexbin}
5 | \title{Add a "hexbin" layer to a Bokeh figure}
6 | \usage{
7 | ly_hexbin(
8 | fig,
9 | x,
10 | y = NULL,
11 | data = figure_data(fig),
12 | xbins = 30,
13 | shape = 1,
14 | xbnds = NULL,
15 | ybnds = NULL,
16 | style = "colorscale",
17 | trans = NULL,
18 | inv = NULL,
19 | lname = NULL,
20 | palette = "RdYlGn11",
21 | line = FALSE,
22 | alpha = 1,
23 | hover = TRUE
24 | )
25 | }
26 | \arguments{
27 | \item{fig}{figure to modify}
28 |
29 | \item{x}{values or field name of center x coordinates to be binned}
30 |
31 | \item{y}{values or field name of center y coordinates to be binned}
32 |
33 | \item{data}{an optional data frame, providing the source for x and y}
34 |
35 | \item{xbins, shape, xbnds, ybnds}{parameters passed to \code{\link[hexbin]{hexbin}}}
36 |
37 | \item{style}{type of plotting for hexbins (see \code{\link[hexbin]{grid.hexagons}}) - "colorramp" and "lattice" are currently supported}
38 |
39 | \item{trans, inv}{transformation and inverse transformation function for the bin counts}
40 |
41 | \item{lname}{layer name}
42 |
43 | \item{palette}{name of color palette to use for color ramp (see \href{https://docs.bokeh.org/en/latest/docs/reference/palettes.html}{here} for acceptable values)}
44 |
45 | \item{line}{logical - should hexagons have an outline?}
46 |
47 | \item{alpha}{the alpha transparency of the hexagons between 0 (transparent) and 1 (opaque)}
48 |
49 | \item{hover}{logical - should a hover tool be added to show the count in each hexagon?}
50 | }
51 | \description{
52 | Add a "hexbin" layer to a Bokeh figure
53 | }
54 | \examples{
55 | \donttest{
56 | figure() \%>\% ly_hexbin(rnorm(10000), rnorm(10000))
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/man/ly_image.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer_image.R
3 | \name{ly_image}
4 | \alias{ly_image}
5 | \title{Add an "image" layer to a Bokeh figure}
6 | \usage{
7 | ly_image(
8 | fig,
9 | z,
10 | rows,
11 | byrow = TRUE,
12 | x = 0,
13 | y = 0,
14 | dw = 1,
15 | dh = 1,
16 | palette = "Spectral10",
17 | dilate = FALSE,
18 | lname = NULL,
19 | lgroup = NULL
20 | )
21 | }
22 | \arguments{
23 | \item{fig}{figure to modify}
24 |
25 | \item{z}{matrix or vector of image values}
26 |
27 | \item{rows}{if \code{z} is a vector, how many rows should be used in treating it as a matrix}
28 |
29 | \item{byrow}{if \code{z} is a vector, should it be turned into a matrix by row}
30 |
31 | \item{x}{lower left x coordinates}
32 |
33 | \item{y}{lower left y coordinates}
34 |
35 | \item{dw}{image width distances}
36 |
37 | \item{dh}{image height distances}
38 |
39 | \item{palette}{name of color palette to use for color ramp (see \href{https://docs.bokeh.org/en/latest/docs/reference/palettes.html}{here} for acceptable values)}
40 |
41 | \item{dilate}{logical - whether to dilate pixel distance computations when drawing}
42 |
43 | \item{lname}{layer name}
44 |
45 | \item{lgroup}{layer group}
46 | }
47 | \description{
48 | Draws a grid of rectangles with colors corresponding to the values in \code{z}
49 | }
50 | \examples{
51 | \donttest{
52 | p <- figure(xlim = c(0, 1), ylim = c(0, 1), title = "Volcano") \%>\%
53 | ly_image(volcano) \%>\%
54 | ly_contour(volcano)
55 | p
56 | }
57 | }
58 | \seealso{
59 | Other layer functions:
60 | \code{\link{ly_abline}()},
61 | \code{\link{ly_annular_wedge}()},
62 | \code{\link{ly_annulus}()},
63 | \code{\link{ly_arc}()},
64 | \code{\link{ly_bar}()},
65 | \code{\link{ly_bezier}()},
66 | \code{\link{ly_boxplot}()},
67 | \code{\link{ly_contour}()},
68 | \code{\link{ly_crect}()},
69 | \code{\link{ly_curve}()},
70 | \code{\link{ly_density}()},
71 | \code{\link{ly_hist}()},
72 | \code{\link{ly_image_url}()},
73 | \code{\link{ly_lines}()},
74 | \code{\link{ly_map}()},
75 | \code{\link{ly_multi_line}()},
76 | \code{\link{ly_oval}()},
77 | \code{\link{ly_patch}()},
78 | \code{\link{ly_points}()},
79 | \code{\link{ly_polygons}()},
80 | \code{\link{ly_quadratic}()},
81 | \code{\link{ly_quantile}()},
82 | \code{\link{ly_ray}()},
83 | \code{\link{ly_rect}()},
84 | \code{\link{ly_segments}()},
85 | \code{\link{ly_text}()},
86 | \code{\link{ly_wedge}()}
87 | }
88 | \concept{layer functions}
89 |
--------------------------------------------------------------------------------
/man/ly_image_url.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer_image.R
3 | \name{ly_image_url}
4 | \alias{ly_image_url}
5 | \title{Add an "image_url" layer to a Bokeh figure}
6 | \usage{
7 | ly_image_url(
8 | fig,
9 | x = 0,
10 | y = 0,
11 | data = figure_data(fig),
12 | w = 10,
13 | h = 10,
14 | image_url,
15 | dilate = TRUE,
16 | anchor = "top_left",
17 | angle = 0,
18 | lname = NULL,
19 | lgroup = NULL
20 | )
21 | }
22 | \arguments{
23 | \item{fig}{figure to modify}
24 |
25 | \item{x}{x coordinates}
26 |
27 | \item{y}{y coordinates}
28 |
29 | \item{data}{an optional data frame, providing the source for inputs x, y, and other properties}
30 |
31 | \item{w, h}{values or field names of width and height of image}
32 |
33 | \item{image_url}{values or field name of image URLs}
34 |
35 | \item{dilate}{logical - whether to dilate pixel distance computations when drawing}
36 |
37 | \item{anchor}{where the image is anchored to with respect to \code{x} and \code{y}}
38 |
39 | \item{angle}{values or field name of the angle to rotate the image, in radians}
40 |
41 | \item{lname}{layer name}
42 |
43 | \item{lgroup}{layer group}
44 | }
45 | \description{
46 | Renders raster images from URLs at provided coordinates
47 | }
48 | \examples{
49 | \donttest{
50 | url <- c(" http://bokeh.pydata.org/en/latest/_static/images/logo.png",
51 | "http://developer.r-project.org/Logo/Rlogo-4.png")
52 |
53 | ss <- seq(0, 2*pi, length = 13)[-1]
54 | ws <- runif(12, 2.5, 5) * rep(c(1, 0.8), 6)
55 |
56 | imgdat <- data.frame(
57 | x = sin(ss) * 10, y = cos(ss) * 10,
58 | w = ws, h = ws * rep(c(1, 0.76), 6),
59 | url = rep(url, 6)
60 | )
61 |
62 | p <- figure(xlab = "x", ylab = "y") \%>\%
63 | ly_image_url(x, y, w = w, h = h, image_url = url, data = imgdat,
64 | anchor = "center") \%>\%
65 | ly_lines(sin(c(ss, ss[1])) * 10, cos(c(ss, ss[1])) * 10,
66 | width = 15, alpha = 0.1)
67 | p
68 | }
69 | }
70 | \seealso{
71 | Other layer functions:
72 | \code{\link{ly_abline}()},
73 | \code{\link{ly_annular_wedge}()},
74 | \code{\link{ly_annulus}()},
75 | \code{\link{ly_arc}()},
76 | \code{\link{ly_bar}()},
77 | \code{\link{ly_bezier}()},
78 | \code{\link{ly_boxplot}()},
79 | \code{\link{ly_contour}()},
80 | \code{\link{ly_crect}()},
81 | \code{\link{ly_curve}()},
82 | \code{\link{ly_density}()},
83 | \code{\link{ly_hist}()},
84 | \code{\link{ly_image}()},
85 | \code{\link{ly_lines}()},
86 | \code{\link{ly_map}()},
87 | \code{\link{ly_multi_line}()},
88 | \code{\link{ly_oval}()},
89 | \code{\link{ly_patch}()},
90 | \code{\link{ly_points}()},
91 | \code{\link{ly_polygons}()},
92 | \code{\link{ly_quadratic}()},
93 | \code{\link{ly_quantile}()},
94 | \code{\link{ly_ray}()},
95 | \code{\link{ly_rect}()},
96 | \code{\link{ly_segments}()},
97 | \code{\link{ly_text}()},
98 | \code{\link{ly_wedge}()}
99 | }
100 | \concept{layer functions}
101 |
--------------------------------------------------------------------------------
/man/ly_multi_line.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer_lines.R
3 | \name{ly_multi_line}
4 | \alias{ly_multi_line}
5 | \title{Add a "multi_line" layer to a Bokeh figure}
6 | \usage{
7 | ly_multi_line(
8 | fig,
9 | xs,
10 | ys,
11 | color = "black",
12 | alpha = 1,
13 | width = 1,
14 | type = 1,
15 | lname = NULL,
16 | lgroup = NULL,
17 | ...
18 | )
19 | }
20 | \arguments{
21 | \item{fig}{figure to modify}
22 |
23 | \item{xs}{list of vectors of x coordinates}
24 |
25 | \item{ys}{list of vectors of y coordinates}
26 |
27 | \item{color}{color to use to stroke lines with - a hex code (with no alpha) or any of the 147 named CSS colors, e.g 'green', 'indigo'}
28 |
29 | \item{alpha}{transparency value for the line between 0 (transparent) and 1 (opaque)}
30 |
31 | \item{width}{stroke width in units of pixels}
32 |
33 | \item{type}{an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use}
34 |
35 | \item{lname}{layer name}
36 |
37 | \item{lgroup}{layer group}
38 |
39 | \item{\ldots}{additional parameters for fine control over line properties (see "Additional parameters" below)}
40 | }
41 | \description{
42 | Draws multiple lines with the given lists of coordinates.
43 | }
44 | \section{Additional parameters}{
45 |
46 | \tabular{ll}{
47 | \code{line_join} \tab how path segments should be joined together 'miter' 'round' 'bevel' \cr
48 | \code{line_cap} \tab how path segments should be terminated 'butt' 'round' 'square' \cr
49 | \code{line_dash} \tab an integer between 1 and 6 matching the \code{lty} property in \code{\link[graphics]{par}} or an array of integer pixel distances that describe the on-off pattern of dashing to use \cr
50 | \code{line_dash_offset} \tab the distance in pixels into the line_dash that the pattern should start from
51 | }
52 | }
53 |
54 | \seealso{
55 | Other layer functions:
56 | \code{\link{ly_abline}()},
57 | \code{\link{ly_annular_wedge}()},
58 | \code{\link{ly_annulus}()},
59 | \code{\link{ly_arc}()},
60 | \code{\link{ly_bar}()},
61 | \code{\link{ly_bezier}()},
62 | \code{\link{ly_boxplot}()},
63 | \code{\link{ly_contour}()},
64 | \code{\link{ly_crect}()},
65 | \code{\link{ly_curve}()},
66 | \code{\link{ly_density}()},
67 | \code{\link{ly_hist}()},
68 | \code{\link{ly_image_url}()},
69 | \code{\link{ly_image}()},
70 | \code{\link{ly_lines}()},
71 | \code{\link{ly_map}()},
72 | \code{\link{ly_oval}()},
73 | \code{\link{ly_patch}()},
74 | \code{\link{ly_points}()},
75 | \code{\link{ly_polygons}()},
76 | \code{\link{ly_quadratic}()},
77 | \code{\link{ly_quantile}()},
78 | \code{\link{ly_ray}()},
79 | \code{\link{ly_rect}()},
80 | \code{\link{ly_segments}()},
81 | \code{\link{ly_text}()},
82 | \code{\link{ly_wedge}()}
83 | }
84 | \concept{layer functions}
85 |
--------------------------------------------------------------------------------
/man/nyctaxihex.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/rbokeh-package.R
3 | \docType{data}
4 | \name{nyctaxihex}
5 | \alias{nyctaxihex}
6 | \title{Hexagon binned counts of NYC taxi pickup locations}
7 | \usage{
8 | nyctaxihex
9 | }
10 | \description{
11 | Counts of NYC taxi pickups by location for January 2013, obtained from \href{https://chriswhong.com/open-data/foil_nyc_taxi/}{here}.
12 | }
13 | \examples{
14 | \dontrun{
15 | gmap(title = "NYC taxi pickups January 2013",
16 | lat = 40.74, lng = -73.95, zoom = 11,
17 | map_type = "roadmap", width = 1000, height = 800) \%>\%
18 | ly_hexbin(nyctaxihex, alpha = 0.5,
19 | palette = "Spectral10", trans = log, inv = exp)
20 | }
21 | }
22 | \keyword{data}
23 |
--------------------------------------------------------------------------------
/man/palettes.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/theme_palettes.R
3 | \name{pal_color}
4 | \alias{pal_color}
5 | \alias{pal_tableau}
6 | \alias{pal_bk_glyph}
7 | \alias{pal_gradient}
8 | \alias{pal_size}
9 | \alias{pal_bk_line_dash}
10 | \alias{pal_bk_line_width}
11 | \title{Palettes for themes}
12 | \usage{
13 | pal_color(colors)
14 |
15 | pal_tableau(pal = "Tableau10")
16 |
17 | pal_bk_glyph()
18 |
19 | pal_gradient(
20 | cols = c("#66C2A4", "#41AE76", "#238B45", "#006D2C", "#00441B"),
21 | space = "rgb"
22 | )
23 |
24 | pal_size(min = 2, max = 20)
25 |
26 | pal_bk_line_dash()
27 |
28 | pal_bk_line_width()
29 | }
30 | \arguments{
31 | \item{colors}{a vector of colors to be used in the color palette}
32 |
33 | \item{pal}{palette name}
34 |
35 | \item{cols}{a vector of colors to ramp across for a continuous palette}
36 |
37 | \item{space}{passed on to \code{\link{colorRampPalette}[grDevices]}}
38 |
39 | \item{min}{minimum value}
40 |
41 | \item{max}{maximum value}
42 | }
43 | \description{
44 | Palettes for themes
45 |
46 | Palettes for themes
47 | }
48 |
--------------------------------------------------------------------------------
/man/phantom_install.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/output_save.R
3 | \name{phantom_install}
4 | \alias{phantom_install}
5 | \title{Instructions for installing phantomjs}
6 | \usage{
7 | phantom_install()
8 | }
9 | \description{
10 | Instructions for installing phantomjs
11 | }
12 |
--------------------------------------------------------------------------------
/man/pipe.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/rbokeh-package.R
3 | \name{\%>\%}
4 | \alias{\%>\%}
5 | \title{Pipe figures}
6 | \arguments{
7 | \item{lhs}{a Bokeh figure}
8 |
9 | \item{rhs}{a layer to add to the figure}
10 | }
11 | \description{
12 | Pipe figures
13 | }
14 |
--------------------------------------------------------------------------------
/man/point_types.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/point_types.R
3 | \name{point_types}
4 | \alias{point_types}
5 | \title{Display glyph types available for ly_points()}
6 | \usage{
7 | point_types(size = 25, color = "blue", width = 800, height = 450)
8 | }
9 | \arguments{
10 | \item{size}{size of the glyph}
11 |
12 | \item{color}{color to use for line and fill properties}
13 |
14 | \item{width, height}{dimensions of output plot}
15 | }
16 | \description{
17 | Display glyph types available for ly_points()
18 | }
19 | \examples{
20 | point_types()
21 | }
22 |
--------------------------------------------------------------------------------
/man/print_model_json.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/output_json.R
3 | \name{print_model_json}
4 | \alias{print_model_json}
5 | \title{Print the JSON of a Bokeh figure}
6 | \usage{
7 | print_model_json(fig, prepare = TRUE, pretty = TRUE, file = "", pbcopy = FALSE)
8 | }
9 | \arguments{
10 | \item{fig}{figure to print}
11 |
12 | \item{prepare}{logical - should the figure be sent through preparations that need to be done prior to plotting (TRUE), or printed as-is (FALSE)}
13 |
14 | \item{pretty}{parameter passed on to \code{\link[jsonlite]{toJSON}}}
15 |
16 | \item{file}{parameter passed on to \code{\link[base]{cat}}}
17 |
18 | \item{pbcopy}{logical - if on OSX, should the results be passed to the clipboard (TRUE) instead of printed to the screen (FALSE)?}
19 | }
20 | \description{
21 | Print the JSON of a Bokeh figure
22 | }
23 | \examples{
24 | \dontrun{
25 | p <- figure() \%>\% ly_points(1:10) \%>\%
26 | tool_pan(dimensions = "height")
27 | print_model_json(p)
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/man/rbokeh-package.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/rbokeh-package.R
3 | \docType{package}
4 | \name{rbokeh-package}
5 | \alias{rbokeh-package}
6 | \alias{rbokeh}
7 | \title{rbokeh: R interface for Bokeh}
8 | \description{
9 | R interface for creating plots in Bokeh. Bokeh by Continuum Analytics, \url{https://docs.bokeh.org/en/latest/}
10 | }
11 | \details{
12 | For full documentation on the package, visit \url{https://hafen.github.io/rbokeh/}
13 | }
14 |
--------------------------------------------------------------------------------
/man/rbokeh2html.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/output_html.R
3 | \name{rbokeh2html}
4 | \alias{rbokeh2html}
5 | \title{Get the HTML content required to embed a Bokeh figure}
6 | \usage{
7 | rbokeh2html(
8 | fig,
9 | file = tempfile(fileext = ".html"),
10 | pretty = FALSE,
11 | secure = TRUE
12 | )
13 | }
14 | \arguments{
15 | \item{fig}{figure}
16 |
17 | \item{file}{html file name to write the figure to}
18 |
19 | \item{pretty}{should the json model be pretty printed to the html file?}
20 |
21 | \item{secure}{should https be used for cdn links?}
22 | }
23 | \description{
24 | Get the HTML content required to embed a Bokeh figure
25 | }
26 | \examples{
27 | p <- figure() \%>\% ly_points(1:10)
28 | rbokeh2html(p)
29 | }
30 |
--------------------------------------------------------------------------------
/man/rbokehOutput.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/shiny.R
3 | \name{rbokehOutput}
4 | \alias{rbokehOutput}
5 | \title{Widget output function for use in Shiny}
6 | \usage{
7 | rbokehOutput(outputId, width = "100\%", height = "400px")
8 | }
9 | \arguments{
10 | \item{outputId}{output variable to read from}
11 |
12 | \item{width}{a valid CSS unit for the width or a number, which will be coerced to a string and have "px" appended.}
13 |
14 | \item{height}{a valid CSS unit for the height or a number, which will be coerced to a string and have "px" appended.}
15 | }
16 | \description{
17 | Widget output function for use in Shiny
18 | }
19 | \examples{
20 | \dontrun{
21 | library("shiny")
22 | library("rbokeh")
23 |
24 | ui <- fluidPage(
25 | rbokehOutput("rbokeh")
26 | )
27 |
28 | server <- function(input, output, session) {
29 | output$rbokeh <- renderRbokeh({
30 | # Use invalidateLater() and jitter() to add some motion
31 | invalidateLater(1000, session)
32 | figure() \%>\%
33 | ly_points(jitter(cars$speed), jitter(cars$dist))
34 | })
35 | }
36 |
37 | shinyApp(ui, server)
38 |
39 |
40 | library("shiny")
41 | library("rbokeh")
42 |
43 | ui <- fluidPage(
44 | rbokehOutput("rbokeh", width = 500, height = 540),
45 | textOutput("x_range_text")
46 | )
47 |
48 | server <- function(input, output, session) {
49 | output$rbokeh <- renderRbokeh({
50 | figure() \%>\% ly_points(1:10) \%>\%
51 | x_range(callback = shiny_callback("x_range"))
52 | })
53 |
54 | output$x_range_text <- reactive({
55 | xrng <- input$x_range
56 | if(!is.null(xrng)) {
57 | paste0("factors: ", xrng$factors, ", start: ", xrng$start,
58 | ", end: ", xrng$end)
59 | } else {
60 | "waiting for axis event..."
61 | }
62 | })
63 | }
64 |
65 | shinyApp(ui, server)
66 | }
67 | }
68 |
--------------------------------------------------------------------------------
/man/renderRbokeh.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/shiny.R
3 | \name{renderRbokeh}
4 | \alias{renderRbokeh}
5 | \title{Widget render function for use in Shiny}
6 | \usage{
7 | renderRbokeh(expr, env = parent.frame(), quoted = FALSE)
8 | }
9 | \arguments{
10 | \item{expr}{an expression that generates a rbokeh figure}
11 |
12 | \item{env}{the environment in which to evaluate expr.}
13 |
14 | \item{quoted}{is expr a quoted expression (with quote())? This is useful if you want to save an expression in a variable.}
15 | }
16 | \description{
17 | Widget render function for use in Shiny
18 | }
19 | \seealso{
20 | \code{\link{rbokehOutput}} for an example in Shiny
21 | }
22 |
--------------------------------------------------------------------------------
/man/set_theme.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/themes.R
3 | \name{set_theme}
4 | \alias{set_theme}
5 | \title{Set the theme for a figure}
6 | \usage{
7 | set_theme(fig, theme)
8 | }
9 | \arguments{
10 | \item{fig}{a figure to set the theme for}
11 |
12 | \item{theme}{theme}
13 | }
14 | \description{
15 | Set the theme for a figure
16 | }
17 | \examples{
18 | \donttest{
19 | # manually specify a ggplot-like grid and background
20 | figure() \%>\%
21 | ly_points(1:10) \%>\%
22 | theme_plot(background_fill_color = "#E6E6E6",
23 | outline_line_color = "white") \%>\%
24 | theme_grid(c("x", "y"), grid_line_color = "white",
25 | minor_grid_line_color = "white",
26 | minor_grid_line_alpha = 0.4) \%>\%
27 | theme_axis(c("x", "y"), axis_line_color = "white",
28 | major_label_text_color = "#7F7F7F",
29 | major_tick_line_color = "#7F7F7F",
30 | minor_tick_line_alpha = 0, num_minor_ticks = 2)
31 |
32 | # or use the built in ggplot theme (under development)
33 | figure(data = iris, legend = "top_left", tools = NULL) \%>\%
34 | ly_points(Sepal.Length, Petal.Length, color = Species) \%>\%
35 | set_theme(bk_ggplot_theme)
36 | }
37 | \dontrun{
38 | # or to set the theme for all future plots
39 | options(bokeh_theme = bk_ggplot_theme)
40 |
41 | figure() \%>\%
42 | ly_points(1:10)
43 |
44 | figure() \%>\%
45 | ly_boxplot(1:10)
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/man/shiny_callback.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_callback.R
3 | \name{shiny_callback}
4 | \alias{shiny_callback}
5 | \title{Specify a Shiny callback}
6 | \usage{
7 | shiny_callback(id)
8 | }
9 | \arguments{
10 | \item{id}{a name that will be made available in your Shiny app as \code{input$id}}
11 | }
12 | \description{
13 | Specify a Shiny callback
14 | }
15 | \note{
16 | Depending on the type of callback you are using (selection, range, hover, tap), the value of \code{input$id} will change. The best way to get familiar with what to expect as these values is to debug inside your Shiny app and inspect the contents. You can also use \code{\link{custom_callback}} to write your own custom callbacks that can register other data in your Shiny app. To see what the callbacks look like for each callback type, see, for example, the contents of \code{rbokeh:::handle_range_callback.shinyCallback}
17 | }
18 |
--------------------------------------------------------------------------------
/man/sub_names.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/layer__utils.R
3 | \name{sub_names}
4 | \alias{sub_names}
5 | \title{Retrieve and properly parse all data}
6 | \usage{
7 | sub_names(fig, data, arg_obj, process_data_and_names = TRUE)
8 | }
9 | \arguments{
10 | \item{fig}{figure to be used}
11 |
12 | \item{data}{data to be used}
13 |
14 | \item{arg_obj}{args object supplied by \code{grab}}
15 |
16 | \item{process_data_and_names}{boolean to determine if the data and x_name and y_name should be post processed}
17 | }
18 | \value{
19 | list of three groups: data, info, and params
20 | }
21 | \description{
22 | Retrieve and properly parse all data
23 | }
24 |
--------------------------------------------------------------------------------
/man/theme_grid.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/theme_grid.R
3 | \name{theme_grid}
4 | \alias{theme_grid}
5 | \title{Override theme parameters for grid attributes}
6 | \usage{
7 | theme_grid(
8 | fig,
9 | which = c("x", "y"),
10 | band_fill_alpha = 1,
11 | band_fill_color = "gray",
12 | grid_line_alpha = 1,
13 | grid_line_cap = "butt",
14 | grid_line_color = "black",
15 | grid_line_dash = NULL,
16 | grid_line_dash_offset = 0,
17 | grid_line_join = "miter",
18 | grid_line_width = 1,
19 | minor_grid_line_alpha = 1,
20 | minor_grid_line_cap = "butt",
21 | minor_grid_line_color = "black",
22 | minor_grid_line_dash = NULL,
23 | minor_grid_line_dash_offset = 0,
24 | minor_grid_line_join = "miter",
25 | minor_grid_line_width = 1,
26 | pars = NULL
27 | )
28 | }
29 | \arguments{
30 | \item{fig}{figure to modify}
31 |
32 | \item{which}{which grids to apply attributes to ("x" and/or "y")}
33 |
34 | \item{band_fill_alpha}{The fill alpha of alternating bands between Grid lines.}
35 |
36 | \item{band_fill_color}{The fill color of alternating bands between Grid lines.}
37 |
38 | \item{grid_line_alpha}{The line alpha of the Grid lines.}
39 |
40 | \item{grid_line_cap}{('butt', 'round', 'square') The line cap of the Grid lines.}
41 |
42 | \item{grid_line_color}{The line color of the Grid lines.}
43 |
44 | \item{grid_line_dash}{The line dash of the Grid lines.}
45 |
46 | \item{grid_line_dash_offset}{The line dash offset of the Grid lines.}
47 |
48 | \item{grid_line_join}{('miter', 'round', 'bevel') The line join of the Grid lines.}
49 |
50 | \item{grid_line_width}{The line width of the Grid lines.}
51 |
52 | \item{minor_grid_line_alpha}{The line alpha of the minor Grid lines.}
53 |
54 | \item{minor_grid_line_cap}{('butt', 'round', 'square') The line cap of the minor Grid lines.}
55 |
56 | \item{minor_grid_line_color}{The line color of the minor Grid lines.}
57 |
58 | \item{minor_grid_line_dash}{The line dash of the minor Grid lines.}
59 |
60 | \item{minor_grid_line_dash_offset}{The line dash offset of the minor Grid lines.}
61 |
62 | \item{minor_grid_line_join}{('miter', 'round', 'bevel') The line join of the minor Grid lines.}
63 |
64 | \item{minor_grid_line_width}{The line width of the minor Grid lines.}
65 |
66 | \item{pars}{optionally specify a named list of all parameters - useful when dealing with theme lists}
67 | }
68 | \description{
69 | Override theme parameters for grid attributes
70 | }
71 | \examples{
72 | \donttest{
73 | # manually specify a ggplot-like grid and background
74 | figure() \%>\%
75 | ly_points(1:10) \%>\%
76 | theme_plot(background_fill_color = "#E6E6E6",
77 | outline_line_color = "white") \%>\%
78 | theme_grid(c("x", "y"), grid_line_color = "white",
79 | minor_grid_line_color = "white",
80 | minor_grid_line_alpha = 0.4) \%>\%
81 | theme_axis(c("x", "y"), axis_line_color = "white",
82 | major_label_text_color = "#7F7F7F",
83 | major_tick_line_color = "#7F7F7F",
84 | minor_tick_line_alpha = 0, num_minor_ticks = 2)
85 |
86 | # or use the built in ggplot theme (under development)
87 | figure(data = iris, legend = "top_left", tools = NULL) \%>\%
88 | ly_points(Sepal.Length, Petal.Length, color = Species) \%>\%
89 | set_theme(bk_ggplot_theme)
90 | }
91 | \dontrun{
92 | # or to set the theme for all future plots
93 | options(bokeh_theme = bk_ggplot_theme)
94 |
95 | figure() \%>\%
96 | ly_points(1:10)
97 |
98 | figure() \%>\%
99 | ly_boxplot(1:10)
100 | }
101 | }
102 |
--------------------------------------------------------------------------------
/man/theme_legend.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/theme_legend.R
3 | \name{theme_legend}
4 | \alias{theme_legend}
5 | \title{Override theme parameters for legend attributes}
6 | \usage{
7 | theme_legend(
8 | fig,
9 | background_fill_alpha = 0.95,
10 | background_fill_color = "#fff",
11 | border_line_alpha = 0.5,
12 | border_line_cap = "butt",
13 | border_line_color = "black",
14 | border_line_dash = NULL,
15 | border_line_dash_offset = 0,
16 | border_line_join = "miter",
17 | border_line_width = 1,
18 | glyph_height = 20,
19 | glyph_width = 20,
20 | label_height = 20,
21 | label_standoff = 15,
22 | label_text_align = "left",
23 | label_text_alpha = 1,
24 | label_text_baseline = "bottom",
25 | label_text_color = "#444444",
26 | label_text_font = "Helvetica",
27 | label_text_font_size = "12pt",
28 | label_text_font_style = "normal",
29 | label_width = 50,
30 | legend_padding = 10,
31 | legend_spacing = 3,
32 | pars = NULL
33 | )
34 | }
35 | \arguments{
36 | \item{fig}{figure to modify}
37 |
38 | \item{background_fill_alpha}{(numeric) background color alpha of plot}
39 |
40 | \item{background_fill_color}{(color) background color of plot}
41 |
42 | \item{border_line_alpha}{The line alpha for the legend border outline.}
43 |
44 | \item{border_line_cap}{('butt', 'round', 'square') The line cap for the legend border outline.}
45 |
46 | \item{border_line_color}{The line color for the legend border outline.}
47 |
48 | \item{border_line_dash}{The line dash for the legend border outline.}
49 |
50 | \item{border_line_dash_offset}{The line dash offset for the legend border outline.}
51 |
52 | \item{border_line_join}{('miter', 'round', 'bevel') The line join for the legend border outline.}
53 |
54 | \item{border_line_width}{The line width for the legend border outline.}
55 |
56 | \item{glyph_height}{The height (in pixels) that the rendered legend glyph should occupy.}
57 |
58 | \item{glyph_width}{The width (in pixels) that the rendered legend glyph should occupy.}
59 |
60 | \item{label_height}{The height (in pixels) of the area that legend labels should occupy.}
61 |
62 | \item{label_standoff}{The distance (in pixels) to separate the label from its associated glyph.}
63 |
64 | \item{label_text_align}{('left', 'right', 'center') The text align for the legend labels.}
65 |
66 | \item{label_text_alpha}{The text alpha for the legend labels.}
67 |
68 | \item{label_text_baseline}{('top', 'middle', 'bottom', 'alphabetic', 'hanging') The text baseline for the legend labels.}
69 |
70 | \item{label_text_color}{The text color for the legend labels.}
71 |
72 | \item{label_text_font}{The text font for the legend labels.}
73 |
74 | \item{label_text_font_size}{The text font size for the legend labels.}
75 |
76 | \item{label_text_font_style}{('normal', 'italic', 'bold') The text font style for the legend labels.}
77 |
78 | \item{label_width}{The width (in pixels) of the area that legend labels should occupy.}
79 |
80 | \item{legend_padding}{Amount of padding around the legend.}
81 |
82 | \item{legend_spacing}{Amount of spacing between legend entries.}
83 |
84 | \item{pars}{optionally specify a named list of all parameters - useful when dealing with theme lists}
85 | }
86 | \description{
87 | Override theme parameters for legend attributes
88 | }
89 | \examples{
90 | figure(legend_location = "top_left") \%>\%
91 | ly_points(1:10, legend = "a") \%>\%
92 | theme_legend(border_line_width = 2)
93 | }
94 |
--------------------------------------------------------------------------------
/man/theme_title.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/theme_title.R
3 | \name{theme_title}
4 | \alias{theme_title}
5 | \title{Override theme parameters for general plot attributes}
6 | \usage{
7 | theme_title(
8 | fig,
9 | pars = NULL,
10 | background_fill_color = "white",
11 | background_fill_alpha = 1,
12 | border_fill_color = "white",
13 | border_fill_alpha = 1,
14 | align = "left",
15 | text_alpha = 1,
16 | text_baseline = "bottom",
17 | text_color = "#444444",
18 | text_font = "Helvetica",
19 | text_font_size = "12pt",
20 | text_font_style = "normal"
21 | )
22 | }
23 | \arguments{
24 | \item{fig}{figure to modify}
25 |
26 | \item{pars}{optionally specify a named list of all parameters - useful when dealing with theme lists}
27 |
28 | \item{background_fill_color}{(color) background color of plot}
29 |
30 | \item{background_fill_alpha}{(numeric) background color alpha of plot}
31 |
32 | \item{border_fill_color}{(color) fill color of border area of plot}
33 |
34 | \item{border_fill_alpha}{(numeric) fill color alpha of border area of plot}
35 |
36 | \item{align}{('left', 'right', 'center') The text align for the plot title.}
37 |
38 | \item{text_alpha}{The text alpha for the plot title.}
39 |
40 | \item{text_baseline}{('top', 'middle', 'bottom', 'alphabetic', 'hanging') The text baseline for the plot title.}
41 |
42 | \item{text_color}{(color) The text color for the plot title.}
43 |
44 | \item{text_font}{(string) The text font for the plot title.}
45 |
46 | \item{text_font_size}{(string - e.g. '12pt') The text font size for the plot title.}
47 |
48 | \item{text_font_style}{('normal', 'italic', 'bold') The text font style for the plot title.}
49 | }
50 | \description{
51 | Override theme parameters for general plot attributes
52 | }
53 | \examples{
54 | figure(title = "asdf") \%>\%
55 | ly_points(1:10) \%>\%
56 | theme_title(text_color = "red")
57 | }
58 |
--------------------------------------------------------------------------------
/man/themes.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/themes.R
3 | \name{bk_default_theme}
4 | \alias{bk_default_theme}
5 | \alias{bk_ggplot_theme}
6 | \title{Themes}
7 | \usage{
8 | bk_default_theme()
9 |
10 | bk_ggplot_theme()
11 | }
12 | \description{
13 | Themes
14 |
15 | Themes
16 | }
17 |
--------------------------------------------------------------------------------
/man/tool_box_select.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_box_select}
4 | \alias{tool_box_select}
5 | \title{Add "box_select" tool to a Bokeh figure}
6 | \usage{
7 | tool_box_select(
8 | fig,
9 | callback = NULL,
10 | ref_layer = NULL,
11 | line_color = "black",
12 | line_alpha = 1,
13 | fill_color = "lightgrey",
14 | fill_alpha = 0.5,
15 | line_width = 2,
16 | line_dash = c(4, 4),
17 | level = "overlay"
18 | )
19 | }
20 | \arguments{
21 | \item{fig}{figure to modify}
22 |
23 | \item{callback}{a callback to be applied to this tool - either a character string of javascript code or any one of \code{\link{debug_callback}}, \code{\link{shiny_callback}}, \code{\link{console_callback}}, \code{\link{custom_callback}}}
24 |
25 | \item{ref_layer}{name of the layer that the callback should be applied to}
26 |
27 | \item{line_color, line_alpha, fill_color, fill_alpha, line_width, line_dash, level}{parameters to control the look of the selection bounding region}
28 | }
29 | \description{
30 | Add "box_select" tool to a Bokeh figure
31 | }
32 | \note{
33 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
34 | }
35 | \examples{
36 | \donttest{
37 | figure() \%>\% ly_points(1:10) \%>\%
38 | tool_box_select()
39 | }
40 | }
41 | \seealso{
42 | Other tools:
43 | \code{\link{tool_box_zoom}()},
44 | \code{\link{tool_crosshair}()},
45 | \code{\link{tool_hover}()},
46 | \code{\link{tool_lasso_select}()},
47 | \code{\link{tool_pan}()},
48 | \code{\link{tool_reset}()},
49 | \code{\link{tool_resize}()},
50 | \code{\link{tool_save}()},
51 | \code{\link{tool_tap}()},
52 | \code{\link{tool_wheel_zoom}()}
53 | }
54 | \concept{tools}
55 |
--------------------------------------------------------------------------------
/man/tool_box_zoom.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_box_zoom}
4 | \alias{tool_box_zoom}
5 | \title{Add "box_zoom" tool to a Bokeh figure}
6 | \usage{
7 | tool_box_zoom(
8 | fig,
9 | line_color = "black",
10 | line_alpha = 1,
11 | fill_color = "lightgrey",
12 | fill_alpha = 0.5,
13 | line_width = 2,
14 | line_dash = c(4, 4),
15 | level = "overlay"
16 | )
17 | }
18 | \arguments{
19 | \item{fig}{figure to modify}
20 |
21 | \item{line_color, line_alpha, fill_color, fill_alpha, line_width, line_dash, level}{parameters to control the look of the selection bounding region}
22 | }
23 | \description{
24 | Add "box_zoom" tool to a Bokeh figure
25 | }
26 | \note{
27 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
28 | }
29 | \examples{
30 | \donttest{
31 | figure() \%>\% ly_points(1:10) \%>\%
32 | tool_box_zoom()
33 | }
34 | }
35 | \seealso{
36 | Other tools:
37 | \code{\link{tool_box_select}()},
38 | \code{\link{tool_crosshair}()},
39 | \code{\link{tool_hover}()},
40 | \code{\link{tool_lasso_select}()},
41 | \code{\link{tool_pan}()},
42 | \code{\link{tool_reset}()},
43 | \code{\link{tool_resize}()},
44 | \code{\link{tool_save}()},
45 | \code{\link{tool_tap}()},
46 | \code{\link{tool_wheel_zoom}()}
47 | }
48 | \concept{tools}
49 |
--------------------------------------------------------------------------------
/man/tool_crosshair.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_crosshair}
4 | \alias{tool_crosshair}
5 | \title{Add "crosshair" tool to a Bokeh figure}
6 | \usage{
7 | tool_crosshair(fig)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 | }
12 | \description{
13 | Add "crosshair" tool to a Bokeh figure
14 | }
15 | \note{
16 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
17 | }
18 | \examples{
19 | \donttest{
20 | figure() \%>\% ly_points(1:10) \%>\%
21 | tool_crosshair()
22 | }
23 | }
24 | \seealso{
25 | Other tools:
26 | \code{\link{tool_box_select}()},
27 | \code{\link{tool_box_zoom}()},
28 | \code{\link{tool_hover}()},
29 | \code{\link{tool_lasso_select}()},
30 | \code{\link{tool_pan}()},
31 | \code{\link{tool_reset}()},
32 | \code{\link{tool_resize}()},
33 | \code{\link{tool_save}()},
34 | \code{\link{tool_tap}()},
35 | \code{\link{tool_wheel_zoom}()}
36 | }
37 | \concept{tools}
38 |
--------------------------------------------------------------------------------
/man/tool_hover.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_hover}
4 | \alias{tool_hover}
5 | \title{Add "hover" tool to a Bokeh figure}
6 | \usage{
7 | tool_hover(fig, callback, ref_layer)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{callback}{a callback to be applied to this tool - either a character string of javascript code or any one of \code{\link{debug_callback}}, \code{\link{shiny_callback}}, \code{\link{console_callback}}, \code{\link{custom_callback}}}
13 |
14 | \item{ref_layer}{name of the layer that the callback should be applied to}
15 | }
16 | \description{
17 | Add "hover" tool to a Bokeh figure
18 | }
19 | \note{
20 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
21 | }
22 | \examples{
23 | \donttest{
24 | # hover over the blue points and make the orange points move
25 | figure(title = "hover a blue point") \%>\%
26 | ly_points(1:10, lname = "blue", lgroup = "g1") \%>\%
27 | ly_points(2:12, lname = "orange", lgroup = "g1") \%>\%
28 | tool_hover(custom_callback(
29 | code = "debugger;if(cb_data.index['1d'].indices.length > 0)
30 | orange_data.get('data').x[cb_data.index['1d'].indices] += 0.1
31 | orange_data.trigger('change')", "orange"), "blue")
32 | }
33 | }
34 | \seealso{
35 | Other tools:
36 | \code{\link{tool_box_select}()},
37 | \code{\link{tool_box_zoom}()},
38 | \code{\link{tool_crosshair}()},
39 | \code{\link{tool_lasso_select}()},
40 | \code{\link{tool_pan}()},
41 | \code{\link{tool_reset}()},
42 | \code{\link{tool_resize}()},
43 | \code{\link{tool_save}()},
44 | \code{\link{tool_tap}()},
45 | \code{\link{tool_wheel_zoom}()}
46 | }
47 | \concept{tools}
48 |
--------------------------------------------------------------------------------
/man/tool_lasso_select.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_lasso_select}
4 | \alias{tool_lasso_select}
5 | \title{Add "lasso_select" tool to a Bokeh figure}
6 | \usage{
7 | tool_lasso_select(
8 | fig,
9 | callback = NULL,
10 | ref_layer = NULL,
11 | line_color = "black",
12 | line_alpha = 1,
13 | fill_color = "lightgrey",
14 | fill_alpha = 0.5,
15 | line_width = 2,
16 | line_dash = c(4, 4),
17 | level = "overlay"
18 | )
19 | }
20 | \arguments{
21 | \item{fig}{figure to modify}
22 |
23 | \item{callback}{a callback to be applied to this tool - either a character string of javascript code or any one of \code{\link{debug_callback}}, \code{\link{shiny_callback}}, \code{\link{console_callback}}, \code{\link{custom_callback}}}
24 |
25 | \item{ref_layer}{name of the layer that the callback should be applied to}
26 |
27 | \item{line_color, line_alpha, fill_color, fill_alpha, line_width, line_dash, level}{parameters to control the look of the selection bounding region}
28 | }
29 | \description{
30 | Add "lasso_select" tool to a Bokeh figure
31 | }
32 | \note{
33 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
34 | }
35 | \examples{
36 | \donttest{
37 | figure() \%>\% ly_points(1:10) \%>\%
38 | tool_lasso_select()
39 | }
40 | }
41 | \seealso{
42 | Other tools:
43 | \code{\link{tool_box_select}()},
44 | \code{\link{tool_box_zoom}()},
45 | \code{\link{tool_crosshair}()},
46 | \code{\link{tool_hover}()},
47 | \code{\link{tool_pan}()},
48 | \code{\link{tool_reset}()},
49 | \code{\link{tool_resize}()},
50 | \code{\link{tool_save}()},
51 | \code{\link{tool_tap}()},
52 | \code{\link{tool_wheel_zoom}()}
53 | }
54 | \concept{tools}
55 |
--------------------------------------------------------------------------------
/man/tool_pan.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_pan}
4 | \alias{tool_pan}
5 | \title{Add "pan" tool to a Bokeh figure}
6 | \usage{
7 | tool_pan(fig, dimensions = "both")
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{dimensions}{a vector specifying whether the pan tool should pan with respect to the x axis ("width") and the y axis ("height") or "both"}
13 | }
14 | \description{
15 | Add "pan" tool to a Bokeh figure
16 | }
17 | \note{
18 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
19 | }
20 | \examples{
21 | \donttest{
22 | # only pan on x axis
23 | figure() \%>\% ly_points(1:10) \%>\%
24 | tool_pan(dimensions = "height")
25 | }
26 | }
27 | \seealso{
28 | Other tools:
29 | \code{\link{tool_box_select}()},
30 | \code{\link{tool_box_zoom}()},
31 | \code{\link{tool_crosshair}()},
32 | \code{\link{tool_hover}()},
33 | \code{\link{tool_lasso_select}()},
34 | \code{\link{tool_reset}()},
35 | \code{\link{tool_resize}()},
36 | \code{\link{tool_save}()},
37 | \code{\link{tool_tap}()},
38 | \code{\link{tool_wheel_zoom}()}
39 | }
40 | \concept{tools}
41 |
--------------------------------------------------------------------------------
/man/tool_reset.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_reset}
4 | \alias{tool_reset}
5 | \title{Add "reset" tool to a Bokeh figure}
6 | \usage{
7 | tool_reset(fig)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 | }
12 | \description{
13 | Add "reset" tool to a Bokeh figure
14 | }
15 | \note{
16 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
17 | }
18 | \examples{
19 | \donttest{
20 | figure() \%>\% ly_points(1:10) \%>\%
21 | tool_reset()
22 | }
23 | }
24 | \seealso{
25 | Other tools:
26 | \code{\link{tool_box_select}()},
27 | \code{\link{tool_box_zoom}()},
28 | \code{\link{tool_crosshair}()},
29 | \code{\link{tool_hover}()},
30 | \code{\link{tool_lasso_select}()},
31 | \code{\link{tool_pan}()},
32 | \code{\link{tool_resize}()},
33 | \code{\link{tool_save}()},
34 | \code{\link{tool_tap}()},
35 | \code{\link{tool_wheel_zoom}()}
36 | }
37 | \concept{tools}
38 |
--------------------------------------------------------------------------------
/man/tool_resize.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_resize}
4 | \alias{tool_resize}
5 | \title{Add "resize" tool to a Bokeh figure}
6 | \usage{
7 | tool_resize(fig)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 | }
12 | \description{
13 | Add "resize" tool to a Bokeh figure
14 | }
15 | \note{
16 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
17 | }
18 | \examples{
19 | \donttest{
20 | figure() \%>\% ly_points(1:10) \%>\%
21 | tool_resize()
22 | }
23 | }
24 | \seealso{
25 | Other tools:
26 | \code{\link{tool_box_select}()},
27 | \code{\link{tool_box_zoom}()},
28 | \code{\link{tool_crosshair}()},
29 | \code{\link{tool_hover}()},
30 | \code{\link{tool_lasso_select}()},
31 | \code{\link{tool_pan}()},
32 | \code{\link{tool_reset}()},
33 | \code{\link{tool_save}()},
34 | \code{\link{tool_tap}()},
35 | \code{\link{tool_wheel_zoom}()}
36 | }
37 | \concept{tools}
38 |
--------------------------------------------------------------------------------
/man/tool_save.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_save}
4 | \alias{tool_save}
5 | \title{Add "save" tool to a Bokeh figure}
6 | \usage{
7 | tool_save(fig)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 | }
12 | \description{
13 | Add "save" tool to a Bokeh figure
14 | }
15 | \note{
16 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
17 | }
18 | \examples{
19 | \donttest{
20 | figure() \%>\% ly_points(1:10) \%>\%
21 | tool_save()
22 | }
23 | }
24 | \seealso{
25 | Other tools:
26 | \code{\link{tool_box_select}()},
27 | \code{\link{tool_box_zoom}()},
28 | \code{\link{tool_crosshair}()},
29 | \code{\link{tool_hover}()},
30 | \code{\link{tool_lasso_select}()},
31 | \code{\link{tool_pan}()},
32 | \code{\link{tool_reset}()},
33 | \code{\link{tool_resize}()},
34 | \code{\link{tool_tap}()},
35 | \code{\link{tool_wheel_zoom}()}
36 | }
37 | \concept{tools}
38 |
--------------------------------------------------------------------------------
/man/tool_selection.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_selection.R
3 | \name{tool_selection}
4 | \alias{tool_selection}
5 | \title{Add "selection" tool callback to a Bokeh figure}
6 | \usage{
7 | tool_selection(fig, callback, ref_layer)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{callback}{a callback to be applied to this tool - either a character string of javascript code or any one of \code{\link{debug_callback}}, \code{\link{shiny_callback}}, \code{\link{console_callback}}, \code{\link{custom_callback}}}
13 |
14 | \item{ref_layer}{name of the layer that the callback should be applied to}
15 | }
16 | \description{
17 | This adds a selection callback to be used with the box select or lasso select tools.
18 | }
19 |
--------------------------------------------------------------------------------
/man/tool_tap.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_tap}
4 | \alias{tool_tap}
5 | \title{Add "tap" tool to a Bokeh figure}
6 | \usage{
7 | tool_tap(fig, callback, ref_layer)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{callback}{a callback to be applied to this tool - either a character string of javascript code or any one of \code{\link{debug_callback}}, \code{\link{shiny_callback}}, \code{\link{console_callback}}, \code{\link{custom_callback}}}
13 |
14 | \item{ref_layer}{name of the layer that the callback should be applied to}
15 | }
16 | \description{
17 | Add "tap" tool to a Bokeh figure
18 | }
19 | \note{
20 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
21 | }
22 | \examples{
23 | \donttest{
24 | figure() \%>\%
25 | ly_points(1:10, lname = "points") \%>\%
26 | tool_tap(debug_callback("points"), "points")
27 | }
28 | }
29 | \seealso{
30 | Other tools:
31 | \code{\link{tool_box_select}()},
32 | \code{\link{tool_box_zoom}()},
33 | \code{\link{tool_crosshair}()},
34 | \code{\link{tool_hover}()},
35 | \code{\link{tool_lasso_select}()},
36 | \code{\link{tool_pan}()},
37 | \code{\link{tool_reset}()},
38 | \code{\link{tool_resize}()},
39 | \code{\link{tool_save}()},
40 | \code{\link{tool_wheel_zoom}()}
41 | }
42 | \concept{tools}
43 |
--------------------------------------------------------------------------------
/man/tool_wheel_zoom.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_tool.R
3 | \name{tool_wheel_zoom}
4 | \alias{tool_wheel_zoom}
5 | \title{Add "wheel_zoom" tool to a Bokeh figure}
6 | \usage{
7 | tool_wheel_zoom(fig, dimensions = "both")
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{dimensions}{a vector specifying whether the wheel_zoom tool should zoom with respect to the x axis ("width") and the y axis ("height") or "both"}
13 | }
14 | \description{
15 | Add "wheel_zoom" tool to a Bokeh figure
16 | }
17 | \note{
18 | Tools can be easily specified as a vector of tool names in the \code{tools} argument when instantiating a \code{\link{figure}}. In this case, they are added with defaults. Explicitly calling these \code{tool_} functions will manually add the tool to a figure and allow additional specification of parameters.
19 | }
20 | \examples{
21 | \donttest{
22 | # only zoom on x axis
23 | figure() \%>\% ly_points(1:10) \%>\%
24 | tool_wheel_zoom(dimensions = "height")
25 | }
26 | }
27 | \seealso{
28 | Other tools:
29 | \code{\link{tool_box_select}()},
30 | \code{\link{tool_box_zoom}()},
31 | \code{\link{tool_crosshair}()},
32 | \code{\link{tool_hover}()},
33 | \code{\link{tool_lasso_select}()},
34 | \code{\link{tool_pan}()},
35 | \code{\link{tool_reset}()},
36 | \code{\link{tool_resize}()},
37 | \code{\link{tool_save}()},
38 | \code{\link{tool_tap}()}
39 | }
40 | \concept{tools}
41 |
--------------------------------------------------------------------------------
/man/widget2gist.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/output_gist.R
3 | \name{widget2gist}
4 | \alias{widget2gist}
5 | \title{Export htmlwidget plot to a gist}
6 | \usage{
7 | widget2gist(
8 | widget_string,
9 | name,
10 | created = NULL,
11 | description = "",
12 | license = c("none", "apache-2.0", "bsd-2-clause", "bsd-3-clause", "cc-by-4.0",
13 | "cc-by-nc-4.0", "cc-by-nc-nd-4.0", "cc-by-nc-sa-4.0", "cc-by-nd-4.0", "cc-by-sa-4.0",
14 | "cddl-1.0", "epl-1.0", "gpl-2.0", "gpl-3.0", "lgpl-2.1", "lgpl-3.0", "mit",
15 | "mpl-2.0"),
16 | border = TRUE,
17 | scrolling = FALSE,
18 | secure = TRUE,
19 | view = TRUE
20 | )
21 | }
22 | \arguments{
23 | \item{widget_string}{a string containing R code to create an htmlwidget}
24 |
25 | \item{name}{name of the gist}
26 |
27 | \item{created}{optional string for a "Created by" to preceed the README}
28 |
29 | \item{description}{optional text to go in README.md to describe the gist}
30 |
31 | \item{license}{license under which gist is released - one of those accepted here: \url{https://bl.ocks.org/licenses.txt}}
32 |
33 | \item{border}{should the bl.ocks.org iframe have a border?}
34 |
35 | \item{scrolling}{should the bl.ocks.org iframe scroll?}
36 |
37 | \item{secure}{should https be used for cdn links?}
38 |
39 | \item{view}{should the resulting gist be opened in the browser on bl.ocks.org?}
40 | }
41 | \description{
42 | Export htmlwidget plot to a gist
43 | }
44 | \note{
45 | This requires that you have a github personal access token stored as an environment variable \code{GITHUB_PAT}. See \code{\link[gistr]{gist_create}} for more information.
46 |
47 | Also note that this currently can't handle thumbnails but we are looking into ways to do that.
48 | }
49 | \examples{
50 | \dontrun{
51 | widget2gist("figure() \%>\% ly_points(1:10)", name = "test")
52 | }
53 | }
54 |
--------------------------------------------------------------------------------
/man/widget2png.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/output_save.R
3 | \name{widget2png}
4 | \alias{widget2png}
5 | \title{Make a static png file for an htmlwidget}
6 | \usage{
7 | widget2png(p, file, timeout = 500)
8 | }
9 | \arguments{
10 | \item{p}{htmlwidget object}
11 |
12 | \item{file}{where to save png file}
13 |
14 | \item{timeout}{plot render timeout in milliseconds (see details)}
15 | }
16 | \description{
17 | Make a static png file for an htmlwidget
18 | }
19 | \details{
20 | This uses phantomjs (\url{https://phantomjs.org}) to render your htmlwidget in a headless browser and take a screenshot of it, creating a static output. This assumes that phantomjs has been installed on your machine and is available as a system call. For plots that take longer to load and render, you may need to increase the value of \code{timeout}. Note that this function is experimental.
21 | }
22 | \examples{
23 | \dontrun{
24 | path <- tempfile(fileext = ".png")
25 | figure(tools = NULL) \%>\%
26 | ly_points(1:10) \%>\%
27 | widget2png(path)
28 | }
29 | }
30 |
--------------------------------------------------------------------------------
/man/x_range.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_range.R
3 | \name{x_range}
4 | \alias{x_range}
5 | \title{Update x axis range in a Bokeh figure}
6 | \usage{
7 | x_range(fig, dat = NULL, callback = NULL)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{dat}{either a vector (min, max) if the axis is numeric, or a vector of values if the axis is categorical. In the latter case, the order in which the values are supplied is how they will be arranged on the axis.}
13 |
14 | \item{callback}{TODO}
15 | }
16 | \description{
17 | Update x axis range in a Bokeh figure
18 | }
19 | \examples{
20 | \donttest{
21 | # get data from Duluth site in 'barley' data
22 | du <- subset(lattice::barley, site == "Duluth")
23 |
24 | # plot with default ranges
25 | p <- figure(width = 600) \%>\%
26 | ly_points(yield, variety, color = year, data = du)
27 | p
28 | # y axis is alphabetical
29 |
30 | # manually set x and y axis (y in order of 1932 yield)
31 | p \%>\%
32 | x_range(c(20, 40)) \%>\%
33 | y_range(du$variety[order(subset(du, year == 1932)$yield)])
34 | }
35 | }
36 | \seealso{
37 | Other ranges:
38 | \code{\link{y_range}()}
39 | }
40 | \concept{ranges}
41 |
--------------------------------------------------------------------------------
/man/y_range.Rd:
--------------------------------------------------------------------------------
1 | % Generated by roxygen2: do not edit by hand
2 | % Please edit documentation in R/fig_range.R
3 | \name{y_range}
4 | \alias{y_range}
5 | \title{Update y axis range in a Bokeh figure}
6 | \usage{
7 | y_range(fig, dat = NULL, callback = NULL)
8 | }
9 | \arguments{
10 | \item{fig}{figure to modify}
11 |
12 | \item{dat}{either a vector (min, max) if the axis is numeric, or a vector of values if the axis is categorical. In the latter case, the order in which the values are supplied is how they will be arranged on the axis.}
13 |
14 | \item{callback}{TODO}
15 | }
16 | \description{
17 | Update y axis range in a Bokeh figure
18 | }
19 | \examples{
20 | \donttest{
21 | # get data from Duluth site in 'barley' data
22 | du <- subset(lattice::barley, site == "Duluth")
23 |
24 | # plot with default ranges
25 | p <- figure(width = 600) \%>\%
26 | ly_points(yield, variety, color = year, data = du)
27 | p
28 | # y axis is alphabetical
29 |
30 | # manually set x and y axis (y in order of 1932 yield)
31 | p \%>\%
32 | x_range(c(20, 40)) \%>\%
33 | y_range(du$variety[order(subset(du, year == 1932)$yield)])
34 | }
35 | }
36 | \seealso{
37 | Other ranges:
38 | \code{\link{x_range}()}
39 | }
40 | \concept{ranges}
41 |
--------------------------------------------------------------------------------
/pkgdown/favicon/apple-touch-icon-120x120.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/apple-touch-icon-120x120.png
--------------------------------------------------------------------------------
/pkgdown/favicon/apple-touch-icon-152x152.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/apple-touch-icon-152x152.png
--------------------------------------------------------------------------------
/pkgdown/favicon/apple-touch-icon-180x180.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/apple-touch-icon-180x180.png
--------------------------------------------------------------------------------
/pkgdown/favicon/apple-touch-icon-60x60.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/apple-touch-icon-60x60.png
--------------------------------------------------------------------------------
/pkgdown/favicon/apple-touch-icon-76x76.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/apple-touch-icon-76x76.png
--------------------------------------------------------------------------------
/pkgdown/favicon/apple-touch-icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/apple-touch-icon.png
--------------------------------------------------------------------------------
/pkgdown/favicon/favicon-16x16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/favicon-16x16.png
--------------------------------------------------------------------------------
/pkgdown/favicon/favicon-32x32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/favicon-32x32.png
--------------------------------------------------------------------------------
/pkgdown/favicon/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/hafen/rbokeh/5bf853469c4ffe02c01f37cf06a0ed84cadabbbc/pkgdown/favicon/favicon.ico
--------------------------------------------------------------------------------
/tests/testthat.R:
--------------------------------------------------------------------------------
1 | library(testthat)
2 |
3 | test_check("rbokeh")
4 |
--------------------------------------------------------------------------------
/tests/testthat/test-css-svg.R:
--------------------------------------------------------------------------------
1 |
2 | # see here: https://github.com/bokeh/rbokeh/issues/40
3 | test_that("svgs in css are base64 encoded", {
4 | ff <- file.path(system.file(package = "rbokeh"), "htmlwidgets/lib/bokehjs/bokeh.min.css")
5 | css <- suppressWarnings(readLines(ff))
6 | expect_false(any(grepl("
#grayscale");filter:gray;-webkit-filter:grayscale(100%)}
11 |
12 | # .bk-logo.grey{filter:url("data:image/svg+xml;utf8,
#grayscale");filter:gray;-webkit-filter:grayscale(100%)}
13 |
14 | # then
15 | # base64enc::base64encode(charToRaw("
"))
16 | # then replace it with:
17 | # .bk-logo.grey{filter:url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnPjxmaWx0ZXIgaWQ9J2dyYXlzY2FsZSc+PGZlQ29sb3JNYXRyaXggdHlwZT0nbWF0cml4JyB2YWx1ZXM9JzAuMzMzMyAwLjMzMzMgMC4zMzMzIDAgMCAwLjMzMzMgMC4zMzMzIDAuMzMzMyAwIDAgMC4zMzMzIDAuMzMzMyAwLjMzMzMgMCAwIDAgMCAwIDEgMCcvPjwvZmlsdGVyPjwvc3ZnPg==");filter:gray;-webkit-filter:grayscale(100%)}
18 |
19 | # also update css tooltip colors
20 | # #1e4b6c to #aaa for background and to #888 for border
21 | # #9ab9b1 to #fff
22 | # #e2ddbd to #fff
23 |
--------------------------------------------------------------------------------
/tests/testthat/test-zzz-lintr.R:
--------------------------------------------------------------------------------
1 |
2 | # # https://github.com/jimhester/lintr
3 | # if (requireNamespace("lintr", quietly = TRUE)) {
4 | # context("lints")
5 | # test_that("Package Style", {
6 | # lintr::expect_lint_free(cache = TRUE)
7 | # })
8 | # }
9 |
--------------------------------------------------------------------------------
/vignettes/.gitignore:
--------------------------------------------------------------------------------
1 | *.html
2 | *.R
3 |
--------------------------------------------------------------------------------
/vignettes/rbokeh-pkg.Rmd:
--------------------------------------------------------------------------------
1 | ---
2 | title: "rbokeh"
3 | output: rmarkdown::html_vignette
4 | vignette: >
5 | %\VignetteIndexEntry{rbokeh}
6 | %\VignetteEngine{knitr::rmarkdown}
7 | %\VignetteEncoding{UTF-8}
8 | ---
9 |
10 | Please see the package documentation [here](https://hafen.github.io/rbokeh/).
11 |
--------------------------------------------------------------------------------