gridExtra (version 0.7)

ebimageGrob: create a grob from EBImage object...

Description

create a grob from EBImage object

Usage

ebimageGrob(pic, x=0.5, y=0.5, scale=1, raster=FALSE, angle, ...)

Arguments

pic
object of class Image
x
x unit
y
y unit
scale
numeric scale factor
raster
logical: use rasterGrob(R>=2.11) or imageGrob(RGraphics)
angle
numeric: angle in degrees
...
optional grob parameters, passed to imageGrob or rasterGrob

Value

  • a gTree of class 'ebimage', with natural width and height in points

Examples

Run this code
library(EBImage)
library(RGraphics)
x <- readImage("http://www.google.com/logos/teachersday09.gif")
g1 <- ebimageGrob(x)
dev.new(width=g1$width/72, height=g1$height/72) 
grid.draw(g1)

Run the code above in your browser using DataLab