plotArrayAsImage: Plot a 3D array as an RGB image

Description Usage Arguments Examples

Description

Plots a 3D array as an RGB image in the plot window.

Usage

1
plotArrayAsImage(rgb.array, main = "")

Arguments

rgb.array

3D RGB array with R, G, and B channels (pixel rows x pixel columns x color channels) to be plotted in the plot window as an actual image.

main

Optional title to display for image.

Examples

1
2
3
4
5
6
# Read in image
flowers <- jpeg::readJPEG(system.file("extdata", "flowers.jpg", package =
"countcolors"))

# Plot
plotArrayAsImage(flowers, main = "flowers!")

countcolors documentation built on May 2, 2019, 6:08 a.m.