| read | R Documentation |
Reads all image files from dir (optionally filtered by
pattern) and returns them as a magick-image object.
read(dir, pattern = "")
dir |
path to directory containing the images relative to working directory. |
pattern |
an optional regular expression. Only file names which match the regular expression will be returned. |
an object of class magick-image
Frames are loaded in the order returned by list.files,
which sorts filenames lexicographically. This means the filesystem
filename order determines the stop-motion frame order. Name your files
accordingly (e.g. frame_001.png, frame_002.png, ...) to
guarantee the intended sequence. If you need to reorder frames after
loading, use arrange.
dino_dir <- system.file("extdata", package = "stopmotion")
images <- read(dir = dino_dir)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.