image_square: Squares an image

View source: R/utils_imagem.R

image_squareR Documentation

Squares an image

Description

Converts a rectangular image into a square image by expanding the rows/columns using image_expand().

Usage

image_square(img, plot = TRUE, ...)

Arguments

img

An Image object.

plot

Plots the extended image? defaults to FALSE.

...

Further arguments passed on to image_expand().

Value

The modified Image object.

Examples

library(pliman)
img <- image_pliman("soybean_touch.jpg")
dim(img)
square <- image_square(img)
dim(square)

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

Related to image_square in pliman...