0

I created a slidify with rCharts and works fine on the browser of my computer, but when I open the folder on another computer, the rCharts doesn't appear. Code:

setwd("/home/sergio/Copy/PhDgrive/Conferences/IEA2015/IEA2015/")
require(devtools)
pkgs = c('slidify', 'slidifyLibraries')
install_github(pkgs, 'ramnathv')
install_github('rCharts', 'ramnathv')
install.packages("base64enc")
library(slidify)
library(rCharts)
library(base64enc)
author("IEA2015")
slidify("index.Rmd")
publish(user = "xhie", repo = "IEA2015")

Also, after publishing the project on github, RawGit doesn't render and index.md dosent show rCharts neither. Here is index.Rmd.

---
title       : High resolution emissions inventory for Megacity of São Paulo 
subtitle    : MetroHealth - Instituo de Estudos Avançados USP
author      : Sergio Ibarra Espinosa
job         : PhD student Meteorology IAG/USP
framework   : io2012        # {io2012, html5slides, shower, dzslides, ...}
highlighter : highlight.js  # {highlight.js, prettify, highlight}
hitheme     : io2012      # 
widgets     : [nvd3]             # {mathjax, quiz, bootstrap}
ext_widgets : {rCharts: libraries/nvd3}
mode        : selfcontained ,standalone#, draft
knit        : slidify::knit2slides
---

and here is an example of what I'm not the code with rChart

--- .class1 
## Passenger Cars distribution by age
### Proconve Standard - 14 years average age
```{r, results = 'asis', comment = NA, message = F, echo = F} 
require(knitr)
require(rCharts)
require(base64enc)
setwd("/home/sergio/Copy/PhDgrive/Conferences/IEA2015/IEA2015/")
emi <- read.csv("assets/files/dfsA_PROCONVE.txt")
d1 <- dPlot(
  x = "sanos", 
  y = "df_A.sA", 
  groups = "Standard_PC", 
  data = emi, 
  type = 'bar')
d1$legend( x = 60, y = 10, width = 800, height = 20, horizontalAlign = "left", orderRule = "Ancestry")
d1$show('iframesrc', cdn = FALSE)
```

I want to see the results as the image shows on other computers enter image description here

The repo is here and the link for rPubs is here Thanks!

Josh O'Brien
  • 159,210
  • 26
  • 366
  • 455
Sergio
  • 714
  • 1
  • 8
  • 24

1 Answers1

0

Your graph iframes are referring to local libraries for rendering :

<script src="/home/sergio/R/x86_64-pc-linux-gnu-library/3.2/rCharts/libraries/dimple/js/d3.v3.js" type="text/javascript"></script>
<script src="/home/sergio/R/x86_64-pc-linux-gnu-library/3.2/rCharts/libraries/dimple/js/dimple.v2.1.0.js" type="text/javascript"></script>

So, no script, no render !

David Jacquel
  • 51,670
  • 6
  • 121
  • 147