I am seeing similar problem with using includeHTML(rmarkdown::render("myMarkdown.Rmd")). It messes up other panels. Is there an option to include body only.
Basically, I want to allow user to load a file and obtain a report in html. RMarkdown seems a natural choice, as it can be run and generate a HTML or PDF file the users can print or download. However it seems to interfere with other panels.
Any help is appreciated.
Bob
On Tuesday, May 13, 2014 at 10:08:57 PM UTC-5, Yihui Xie wrote:
Sorry, I meant includeHTML(knitr::knit2html("About.Rmd", fragment.only = TRUE)).
Basically you can put withMathJax() in any UI functions that has the
... argument, e.g. tabPanel().
Regards,
Yihui
On Tue, May 13, 2014 at 11:35 AM, Yihui Xie <yi...@rstudio.com> wrote:
> That is because you included a complete HTML file in the shiny UI, and
> you should only include the content between <body> and </body> in
> About.html.
>
> Instead of includeHTML("About.html"), I think you can try
> HTML(knitr::knit2html("About.Rmd", fragment.only = TRUE)), and you
> also need withMathJax() in ui.R to show LaTeX math expressions.
>
> knitr::knit2html() uses the markdown package, and your About.html was
> generated using rmarkdown and pandoc. At the moment it is not very
> straightforward to create an HTML fragment using the rmarkdown
> package.
>
> Regards,
> Yihui
>
>
> On Tue, May 13, 2014 at 10:59 AM, Aous Abdo <aous...@gmail.com> wrote:
>> When I try to insert an HTML page, which I produce from an Rmd file with
>> knitr, into a shiny app with the IncludeHTML in shiny, some of the fields in
>> the side panel in shiny are all wrong.
>> For example, part of the numericInput field is not visible as you can see
>> here:
>>
>> http://spark.rstudio.com/statstudio/Test/
>>
>> The scripts are available on github:
>> https://github.com/aousabdo/Test