Skip to content

Instantly share code, notes, and snippets.

@ramnathv
Last active December 31, 2015 23:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ramnathv/8064070 to your computer and use it in GitHub Desktop.
Save ramnathv/8064070 to your computer and use it in GitHub Desktop.
library(rCharts)
rPlot(mpg ~ wt, data = mtcars, type = 'point')
library(rCharts)
hair_eye = as.data.frame(HairEyeColor)
p2 <- nPlot(Freq ~ Hair, group = 'Eye', data = subset(hair_eye, Sex == "Female"), type = 'multiBarChart')
p2$chart(color = c('brown', 'red', '#594c26', 'green'))
p2
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
[
{"title": "Example 1: Polychart", "file": "example1.R"},
{"title": "Example 2: NVD3", "file": "example2.R"},
{"title": "Example 3: MorrisJS", "file": "example3.R"}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment