grVizOutput {DiagrammeR} | R Documentation

## Widget output function for use in Shiny

### Description

Widget output function for use in Shiny

### Usage

    grVizOutput(outputId, width = "100%", height = "400px")

### Arguments

`outputId` | output variable to read from
`width` | a valid CSS unit for the width or a number, which will be coerced to a string and have `px` appended.
`height` | a valid CSS unit for the height or a number, which will be coerced to a string and have `px` appended.

### Examples

    ## Not run:
    library(shiny)
    library(shinyAce)

    ui = shinyUI(fluidPage(fluidRow(
      column(
        width=4
        , aceEditor("ace", selectionId = "selection", value="digraph {A;}")
      ),
      column(
        width = 6
        , grVizOutput('diagram' )
      )
    )))

    server = function(input, output){
      output$diagram <- renderGrViz({
        grViz(
          input$ace
        )
      })

    }

    shinyApp(ui = ui, server = server)

    ## End(Not run)

[Package DiagrammeR version 0.8.2 Index]