as_image: Create an 'Image' object

View source: R/utils_imagem.R

as_imageR Documentation

Create an Image object

Description

This function is a simple wrapper around EBImage::Image().

Usage

as_image(data, ...)

Arguments

data

A vector or array containing the pixel intensities of an image. If missing, the default 1x1 zero-filled array is used.

...

Additional arguments passed to EBImage::Image().

Value

An Image object.

Examples

img <-
as_image(rnorm(150 * 150 * 3),
         dim = c(150, 150, 3),
         colormode = 'Color')
plot(img)

pliman documentation built on Oct. 15, 2023, 1:06 a.m.

Related to as_image in pliman...