image_histogram: Image histograms

Description Usage Arguments Details Examples

Description

Histograms are a tool used in photography to visualise the tonal distribution of a picture.

Usage

1
2
3
4
5

Arguments

im

image, such as on read by [image::image_read]

coefficients

luma coefficients

Details

For each channel (red, green, blue), the histogram displays on the tone (from 0 to 255) on the x axis, and the pixel count on the y axis.

The three channels can be combined together to form the brightness histogram.

The 'image_histogram_data' function makes a 'tibble' with 4 columns : - 'tone' : sequence from 0 to 255. - 'red', 'green', 'blue' : pixel count for each channel.

The 'image_histogram_brightness' makes a 'ggplot' object showing the brightness histogram.

The 'image_histogram_rgb' makes a 'ggplot' object showing the histograms for each channel.

Examples

1
2
3
4
5
6
7
## Not run: 
tigrou <- image_read( "inst/tigrou/tigrou.jpg")
image_histogram_data(tigrou)
image_histogram_brightness(tigrou)
image_histogram_rgb(tigrou)

## End(Not run)

ThinkRstat/collage documentation built on May 6, 2019, 7:25 a.m.