将 Markdown 另存为交互式 HTML
Save Markdown as interactive HTML
是否可以将此交互式降价报告转换为 html 并将其保存到特定文件夹(目的是使此报告在 R 之外保持活动状态)?如果是,如何?
---
runtime: shiny
output: html_document
---
```{r echo=FALSE}
N<-c('A','B','C'); V<-c(60,50,80); mydf<-data.frame(N,V)
selectInput("sel","Select:",choices = as.character(mydf$N))
renderText({
paste("The result is:",mydf[mydf$N==input$sel,2])
})
```
谢谢&问候
从 Rstudio 中的设置(run document
旁边),选择 Preview in Viewer Panel
。这将使用您的浏览器,而不是 Rstudio 的 built-in 浏览器。
然后你会看到html文件保存在你的硬盘上:
processing file: testing_interactive.Rmd
"C:/Program Files/RStudio/bin/pandoc/pandoc" +RTS -K512m -RTS "C:/Users/TB/AppData/Local/Temp/RtmpKYheKO/testing_interactive.utf8.md" --to html --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output pandoc83c74213d5c.html --smart --email-obfuscation none --standalone --section-divs --template "C:\Rlibs\rmarkdown\rmd\h\default.html" --no-highlight --variable highlightjs=1 --variable "theme:bootstrap" --mathjax --variable "mathjax-url:https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML" --id-prefix section-
output file: C:/Users/TB/AppData/Local/Temp/RtmpKYheKO/testing_interactive.knit.md
Output created: C:/Users/TB/AppData/Local/Temp/RtmpKYheKO/file83c15d05b9c.html
是否可以将此交互式降价报告转换为 html 并将其保存到特定文件夹(目的是使此报告在 R 之外保持活动状态)?如果是,如何?
---
runtime: shiny
output: html_document
---
```{r echo=FALSE}
N<-c('A','B','C'); V<-c(60,50,80); mydf<-data.frame(N,V)
selectInput("sel","Select:",choices = as.character(mydf$N))
renderText({
paste("The result is:",mydf[mydf$N==input$sel,2])
})
```
谢谢&问候
从 Rstudio 中的设置(run document
旁边),选择 Preview in Viewer Panel
。这将使用您的浏览器,而不是 Rstudio 的 built-in 浏览器。
然后你会看到html文件保存在你的硬盘上:
processing file: testing_interactive.Rmd
"C:/Program Files/RStudio/bin/pandoc/pandoc" +RTS -K512m -RTS "C:/Users/TB/AppData/Local/Temp/RtmpKYheKO/testing_interactive.utf8.md" --to html --from markdown+autolink_bare_uris+ascii_identifiers+tex_math_single_backslash --output pandoc83c74213d5c.html --smart --email-obfuscation none --standalone --section-divs --template "C:\Rlibs\rmarkdown\rmd\h\default.html" --no-highlight --variable highlightjs=1 --variable "theme:bootstrap" --mathjax --variable "mathjax-url:https://cdn.mathjax.org/mathjax/latest/MathJax.js?config=TeX-AMS-MML_HTMLorMML" --id-prefix section-
output file: C:/Users/TB/AppData/Local/Temp/RtmpKYheKO/testing_interactive.knit.md
Output created: C:/Users/TB/AppData/Local/Temp/RtmpKYheKO/file83c15d05b9c.html