plot_histogram_general | R Documentation |
plot a nicer-looking histogram
plot_histogram_general( vec, special_value, breaks, vline_values, limits, plot_title, plot_xlab )
vec |
numeric vector of valuse from which to make histogram |
special_value |
optional parameter. If specified, should be numeric vector of length 1. Plot the bar for this value in a different colour. Used, for example, to draw attention to the bar at x = 0. |
breaks |
optional parameter. If specified, should be numeric vector. Specifies breaks on horizontal axis. If not given, use horizontal axis limits as breaks. |
vline_values |
optional parameter. If specified, should be numeric vector. Plot vertical lines at these values. |
limits |
optional parameter. If specified, should be numeric vector of length 2. Use as horizontal axis limits. If not given use the range of vec (if there are values below 0) or 0, max(vec) (if there are no values below zero). |
plot_title |
optional parameter. If specified, should be character vector of length 1. Title of plot. |
plot_xlab |
character vector of length 1. Horizontal axis label. |
ggplot object
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.