我正在学习Shiny
做事的方法。我想将Shiny
代码嵌入到Rmarkdown
文档中。我正在查看shiny-cheatsheet
但是有正常的方法来构建应用程序; ui and server
。如何使此代码在Rmarkdown
```{r , echo=FALSE}
inputPanel(
numericInput(inputId = "amount",
label = "Enter Amount",
value = 1)
)
result <- renderText({
input$amount * 3.025
})
textOutput(outputId = "result")
```