在knitr html文档中显示googleVis图

时间:2016-01-07 14:59:56

标签: r knitr r-markdown knitrbootstrap

我是使用googleVis的新手,并且遇到了一个我不知道如何管理的问题。如何在html knitr文档中显示googleVis图形?,我看到一些模板并制作此代码



---
output:
  knitrBootstrap::bootstrap_document:   
    title: "Test file"
    theme: spacelab
    highlight: Tomorrow
    theme.chooser: FALSE
    highlight.chooser: FALSE
---
```{r results='asis',echo=FALSE,fig.width=14, fig.height=8,fig.align='center', message=F, warning=F}
load("CLTVT.RData") #<-table with data
suppressPackageStartupMessages(library(googleVis))
A4=gvisMotionChart(CLTVT, 
                       idvar="CLTV", 
                       timevar="FECHA")
print(A4,tag='chart')
```
&#13;
&#13;
&#13;

但是当我运行此代码(在Rstudio中)时,会显示绘图的空间,但是显示为空白(当我直接在R中绘制该绘图时,绘图显示没有问题)。我错过了正确运行此代码的一些细节?,感谢您的帮助

0 个答案:

没有答案
相关问题