I tried to display the googleVis diagram on the rmarkdown page, but it does not work ... Instead, it displays the R code in the browser.
Result
function ()
{
chart <- func()
paste(chart$html$chart, collapse = "\n")
}
<environment: 0x5bd7558>
code
```{r echo=F}
library(googleVis)
df <- data.frame(country=c("US", "GB", "BR"), val1=c(1,3,4), val2=c(23,12,32))
renderGvis({
gvisColumnChart(df, xvar="country", yvar=c("val1", "val2"))
})
```
source
share