BB_hor_distribution: Horizontal distribution of Brilliant Blue in Snow image

Description Usage Arguments Value Author(s) Examples

View source: R/BB_hor_distribution.R

Description

A simple function that processes the result of BB_filter and returns a vector with fractions over the length of an image of a sprinkling experiment with Brilliant Blue.

Usage

1
BB_hor_distribution(filtered_image, blue_selection = "all")

Arguments

filtered_image

the returned matrix of the function BB_filter with values 0, 1, 2 and 3

blue_selection

the blue to consider. By default, the value for blue_selection is 'all'

  • 'all' (all blues)

  • 'dark blue' (only dark blue),

  • 'medium blue' (only medium blues) or

  • 'light blue' (only light blues).

Value

Returns the vertical distribution of blue color as a vector.

Author(s)

Johanna Bloecher, bloecher@fzp.czu.cz

Examples

1
2
3
4
5
6
library(jpeg)
raw_image <- <- readJPEG(system.file("example.jpg", package = "bluesnow"))
## Apply filter to raw image data
BB_filtered_image <- BB_filter(rgb_image = raw_image)
BB_h_dist <- BB_hor_distribution(filtered_image = BB_filtered_image, blue_selection = 'all')
plot(BB_h_dist, xlab = "Width [Pixels]", ylab = "Fraction of Blue [-]")

Jorub/bluesnow documentation built on Oct. 30, 2019, 8:02 p.m.