mjs_hist

0th

Percentile

Shortcut for plotting MetricsGraphics histograms

This function performs the call to mjs_plot and assumes data is a numeric vector. It's intended to save keystrokes when plotting quick histograms. This function automatically a y axis label "Frequency" which you can override with a call to mjs_labs.

Usage
mjs_hist(data, bins = NULL, bar_margin = 1)
Arguments
data
numeric vector
bins
number of bins for the histogram (NULL == let MetricsGraphcis.js library compute)
bar_margin
space between bars (defaults to 1)
Value

metricsgraphics object

Aliases
  • mjs_hist
Examples
bimod <- c(rnorm(1000, 0, 1), rnorm(1000, 3, 1))

mjs_plot(bimod) %>% mjs_histogram()
bimod %>% mjs_hist()

mjs_plot(bimod) %>% mjs_histogram(bins=30)
bimod %>% mjs_hist(30)
Documentation reproduced from package metricsgraphics, version 0.9.0, License: MIT + file LICENSE

Community examples

Looks like there are no examples yet.