Learn R Programming

Rvision (version 0.6.0)

nrow.Rcpp_Image: The Number of Rows/Columns/Channels of an Image

Description

nrow, ncol and nchan return the number of rows, columns or channels present in an Image object.

Usage

nrow.Rcpp_Image(x)
ncol.Rcpp_Image(x)
nchan(x)

Arguments

x

An Image object.

Value

A numeric value.

See Also

dim which returns all dimensions.

Examples

Run this code
# NOT RUN {
balloon <- image(system.file("sample_img/balloon1.png", package = "Rvision"))
nrow(balloon)
ncol(balloon)
nchan(balloon)

# }

Run the code above in your browser using DataLab