getOutline: Determine boundary between foreground and background in an...

Description Usage Arguments Value

View source: R/text.r

Description

Determine boundary between foreground and background in an image

Usage

1
getOutline(imdf, var = "red", threshold = 0.5)

Arguments

imdf

dataframe describing a pixellated image in x and y. Has to have columns x, y, and var

var

dimension along which foreground and background of a shape in the image are well separated. Usually one of 'red', 'green', or 'blue', but could be extended to any other numerical variable.

threshold

value specifying the cutoff along variable var. Values of var higher than the threshold are considered to belong to the foreground.

Value

subset of data frame imdf consisting of just boundary points:


gglogo documentation built on Jan. 29, 2020, 1:09 a.m.