RGBtoGRAY: converting RGB image to gray image

Description Usage Arguments Value Examples

View source: R/rgb2gray.R

Description

Documentation for the RGBtoGRAY function

Usage

1
RGBtoGRAY(m, n = 3, Red = 1, Green = 2, Blue = 3)

Arguments

m

Input image

n

Number of bands in the image (default is 3)

Red

Band number of red (default is 1)

Green

Band number of green (default is 2)

Blue

Band number of blue (default is 3)

Value

an object of class "grayimage"

Examples

1
2
3
4
5
6
## Not run: 
library(stars)
imgRGB <- read_stars(system.file("extdata/image.tif", package="ImageSegmentation"))
RGBtoGRAY(imgRGB,3,1,2,3)

## End(Not run)

Chamodi88/ImageSegmentation documentation built on July 9, 2020, 9:21 p.m.