freewall-shiny {freewall}R Documentation

Shiny bindings for 'freewall'

Description

Output and render functions for using freewall within Shiny applications and interactive Rmd documents.

Usage

freewallOutput(outputId, width = "100%", height = "auto")

renderFreewall(expr, env = parent.frame(), quoted = FALSE)

Arguments

outputId

output variable to read from

width, height

a valid CSS dimension (like "100%", "400px", "auto") or a number, which will be coerced to a string and have "px" appended

expr

an expression that generates a freewall

env

the environment in which to evaluate expr

quoted

logical, whether expr is a quoted expression (with quote()); this is useful if you want to save an expression in a variable

Value

freewallOutput returns an output element that can be included in a Shiny UI definition, and renderFreewall returns a shiny.render.function object that can be included in a Shiny server definition.

Examples

if(require(shiny) && interactive()) {
library(shiny)
library(freewall)

ui <- fluidPage(
  freewallOutput("fw")
)

server <- function(input, output, session) {
  output$fw <- renderFreewall({
    freewall(alphabet(), widths = 200, cellW = 200, cellH = "auto")
  })
}

shinyApp(ui, server)
}


[Package freewall version 1.0.0 Index]