Description Usage Arguments Value Note Examples
This function adds a bar "geom" to a metricsgraphics.js html widget.
1 |
mjs |
metricsgraphics plot object |
bar_height |
width of bars |
binned |
is data already binned? (default: |
metricsgraphics object
metricsgraphics.js currently has "meh" support for bar charts
1 2 3 4 | data.frame(year=seq(1790, 1970, 10),
uspop=as.numeric(uspop)) %>%
mjs_plot(x=year, y=uspop, width=300, height=400) %>%
mjs_bar()
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.