Skip to content

frederikziebell/gghist

Repository files navigation

gghist: Quickly draw a histogram using ggplot2

R build status

gghist is a wrapper around ggplot2’s geom_histogram() to easily plot a histogram of a numeric vector. This is especially useful, since qplot() was deprecated in ggplot2 3.4.0.

Installation

You can install the current release from CRAN via

install.packages("gghist")

or the development version from Github via

devtools::install_github("frederikziebell/gghist")

Example

library(gghist)

x <- rnorm(100)
gghist(x)
#> `stat_bin()` using `bins = 30`. Pick better value with `binwidth`.

x <- exp(rnorm(1000))
gghist(x, bins = 100, fill = "firebrick") + 
  scale_x_log10()

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages