Example Code:
ui <- fluidPage(
withMathJax(),
tags$div(HTML("<script type='text/x-mathjax-config'>
MathJax.Hub.Config({
tex2jax: {inlineMath: [['$','$'], ['\\(','\\)']]}
});
</script>
")),
sidebarPanel(sliderInput("k", "(k_{test})", value=2, min=1, max=3)),
mainPanel(uiOutput("out"))
)
server <- function(input, output, session){
output$out <- renderUI({ paste("(k_{test}=)", input$k)})
}
shinyApp(ui, server)
Here is my Problem: Initially, the app works fine. When changing the input on the slider, however, the output equation loses its format and I don't know how to fix this.
Thanks in advance!