crop: Crop image

View source: R/downsize.R

cropR Documentation

Crop image

Description

Crop image

Usage

crop(im, left = 0, top = 0, right = 0, bottom = 0)

Arguments

im

An image object of package magick.

left

Number of pixels to crop to the left

top

Number of pixels to crop to the top

right

Number of pixels to crop to the right

bottom

Number of pixels to crop to the bottom

Value

An image object of package Magick of reduced or equal size.

Examples

plot(im0 <- magick::image_read("https://goo.gl/nRQi5n"))
plot(crop(im0, top = 200))

privefl/pixelart documentation built on Oct. 29, 2024, 10:13 a.m.