Use the Javascript features for your R charts


rAmCharts is an R package for interactive charts. It is based on the javascript library amcharts.js ( Currently it implements most of the functionnalities found in the distributions CHARTS and STOCK CHARTS. You’ll find the source code and bug reports on our github page, do not hesitate to send your bugs and your comments.

Based on htmlwidgets, it is compatible with shiny, R Markdown documents and RStudio viewer.


Package is on CRAN.


# can have new features in developpement version 


  • The package uses internally pipeR which is usefull to draw complex charts by keeping a certain level of readability in the code. The function mainly used is %>>% (or pipeline()) but the package allow to do many more, see the official tutorial at

For those who are not familiar with the ‘pipe style’ the following lines are equivalent:

head(x = get("iris", "package:datasets"), n = 3)
# or
get("iris", "package:datasets") %>>% head(n = 3)
# or
  get("iris", "package:datasets"),
  head(n = 3)
##   Sepal.Length Sepal.Width Petal.Length Petal.Width Species
## 1          5.1         3.5          1.4         0.2  setosa
## 2          4.9         3.0          1.4         0.2  setosa
## 3          4.7         3.2          1.3         0.2  setosa

Important notice

For all charts generated by R code you’ll see in this introduction, you see a call to the method plot(). It is only necessary for using the package in rmarkdown reports. For other use for instance in the R Studio viewer or shiny applications the method the plot is optionnal.

Find help

  • We have developped few examples in an app with shiny and shinydashboard, run `runExamples()’.

  • If you have some questions about properties to custom a chart you may find solutions in the online amcharts API at