generate_edges: Generate an edge image of a mask, based on an image

Description Usage Arguments Examples

View source: R/utils.R

Description

Generate an edge image of a mask, based on an image

Usage

1
generate_edges(img, mask, opac = c(1, 0.2), cols = c("#440154FF", "#FDE725FF"))

Arguments

img

image

mask

mask

opac

numeric vector o length 2 with the opacity of the overlaid colours

cols

color of the outline and fill that will be used

Examples

1
2
3
4
5
x = readImage(system.file('images', 'shapes.png', package='EBImage'))
sobel <- sobel_filter(x)
edges <- generate_edges(x, sobel < 0.5)
display(edges, "raster")
display(generate_edges(x, EBImage::fillHull(sobel > 0.5)), "raster")

jspaezp/clasifierrr documentation built on March 2, 2020, 11:20 a.m.