Learn R Programming

Rvision (version 0.4.2)

scharr: Calculates an Image Derivatives Using a Scharr Operator

Description

scharr calculates the derivatives of an image using a Scharr operator.

Usage

scharr(image, dx = 1, dy = 1, scale = 1, in_place = FALSE)

Arguments

image

An Image object.

dx

Order of the x derivative (default: 1).

dy

Order of the y derivative (default: 1),

scale

The scale factor for the computed derivative values (default: 1).

in_place

A logical indicating whether the change should be applied to the image itself (TRUE, faster but destructive) or to a copy of it (FALSE, the default, slower but non destructive).

Value

An Image object if in_place=FALSE. Otherwise, it returns nothing and modifies image in place.

See Also

Image, sobel

Examples

Run this code
# NOT RUN {
balloon <- image(system.file("sample_img/balloon1.png", package = "Rvision"))
balloon_scharr <- scharr(balloon, 1, 1, 1)
plot(balloon_scharr)

# }

Run the code above in your browser using DataLab