freewall-shiny | R Documentation |
Output and render functions for using freewall
within
Shiny applications and interactive Rmd documents.
freewallOutput(outputId, width = "100%", height = "auto")
renderFreewall(expr, env = parent.frame(), quoted = FALSE)
outputId |
output variable to read from |
width , height |
a valid CSS dimension (like |
expr |
an expression that generates a |
env |
the environment in which to evaluate |
quoted |
logical, whether |
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.
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)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.