Output and render functions for using hic() within Shiny applications and
interactive R Markdown / Quarto documents.
Usage
hicOutput(output_id, width = "100%", height = "480px")
renderHic(expr, env = parent.frame(), quoted = FALSE)Arguments
- output_id
Output variable to read from.
- width, height
Element size, passed to
htmlwidgets::shinyWidgetOutput().- expr
An expression that generates a
hic()widget.- env
The environment in which to evaluate
expr.- quoted
Is
expralready quoted? Defaults toFALSE.
Examples
if (interactive() && requireNamespace("shiny", quietly = TRUE)) {
ui <- fluidPage(hicOutput("h"))
server <- function(input, output) {
output$h <- renderHic({
hic(matrix(runif(100), 10, 10))
})
}
shinyApp(ui, server)
}