-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathREADME.Rmd
54 lines (40 loc) · 1.28 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
# rfrappe
[![Build Status](https://travis-ci.org/merlinoa/rfrappe.svg?branch=master)](https://travis-ci.org/merlinoa/rfrappe)
[![CRAN_Status_Badge](http://www.r-pkg.org/badges/version/pkgdown)](https://cran.r-project.org/package=rfrappe)
`rfrappe` is an R htmlwidget for the [Frappe Charts](https://github.com/frappe/charts) JavaScript library. Frappe Charts creates simple, responsive, modern SVG charts with zero dependencies.
## Example
![Frappe Example](img/example.gif)
Above gif copied from the [Frappe Charts](https://github.com/frappe/charts/blob/master/README.md) README.
## Installation
```{r, eval = FALSE}
devtools::install_github("merlinoa/rfrappe")
```
## Usage
```{r, fig.width=9}
library(rfrappe)
data <- list(
labels = c("12am-3am", "3am-6pm", "6am-9am", "9am-12am", "12pm-3pm",
"3pm-6pm", "6pm-9pm", "9am-12am"),
datasets = list(
list(
title = "Some Data",
color = "light-blue",
values = c(25, 40, 30, 35, 8, 52, 17, -4)
),
list(
title = "Another Set",
color = "violet",
values = c(25, 50, -10, 15, 18, 32, 27, 14)
)
)
)
rfrappe(list(
title = "My Awesome Bar Chart",
data = data,
type = "bar"
))
```