read.ijroi | R Documentation |
Read an ImageJ ROI file. This returns a structure containing the ImageJ data.
read.ijroi(file, verbose = FALSE)
file |
Name of ImageJ ROI file to read |
verbose |
Whether to report information |
A structure of class ijroi
containing the ROI information
David Sterratt
plot.ijroi
for plotting single ROI objects.
read.ijzip
for reading several ROI objects from .zip files.
library(png)
path <- file.path(system.file(package = "RImageJROI"), "extdata", "ijroi")
im <- as.raster(readPNG(file.path(path, "imagej-logo.png")))
plot(NA, NA, xlim=c(0, ncol(im)), ylim=c(nrow(im), 0), asp=1)
rasterImage(im, 0, nrow(im), ncol(im), 0, interpolate=FALSE)
r <- read.ijroi(file.path(path, "rect.roi"))
plot(r, TRUE)
r <- read.ijroi(file.path(path, "polygon.roi"))
plot(r, TRUE)
r <- read.ijroi(file.path(path, "oval.roi"))
plot(r, TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.