Loading...
 
RR Code
# Testing rCharts from http://ramnathv.github.io/rCharts/
if(!require(devtools)){ install.packages("devtools", repos="http://ftp.heanet.ie/mirrors/cran.r-project.org/") }
require('devtools', quietly = TRUE )
if(!require(rCharts)){ install_github('rCharts', 'ramnathv') }

# We will use a data set from package ggplot2, so we install it if needed
if(!require(ggplot2)){ install.packages("ggplot2", repos="http://ftp.heanet.ie/mirrors/cran.r-project.org/") }
data(economics, package = "ggplot2")
econ <- transform(economics, date = as.character(date))
m1 <- mPlot(x = "date", y = c("psavert", "uempmed"), type = "Line", data = econ)
m1$set(pointSize = 0, lineWidth = 1)
#m1$print("chart2")
m1$LIB[2] <- "https://r.tiki.org/rcharts_libraries/morris"
m1$save("m1.html")


{iframe name="myChart" width="850" height="500" align="middle" frameborder="0" marginheight="0" marginwidth="0" scrolling="auto" src="temp/cache/r.tiki.org/R_r_test09_rcharts_morris/m1.html"}





Show php error messages