Crandore Hub

showimage

Show an Image on an 'R' Graphics Device

Sometimes it is handy to be able to view an image file on an 'R' graphics device. This package just does that. Currently it supports 'PNG' files.

README

```{r, setup, echo = FALSE, message = FALSE}
knitr::opts_chunk$set(
  comment = "#>",
  tidy = FALSE,
  error = FALSE,
  fig.path = "inst/",
  fig.width = 8,
  fig.height = 8)
```

# showimage

> Show an Image on an R Graphics Device

[![Project Status: Active - The project has reached a stable, usable state and is being actively developed.](http://www.repostatus.org/badges/latest/active.svg)](http://www.repostatus.org/#active)
[![Linux Build Status](https://travis-ci.org/r-lib/showimage.svg?branch=master)](https://travis-ci.org/r-lib/showimage)
[![Windows Build status](https://ci.appveyor.com/api/projects/status/github/r-lib/showimage?svg=true)](https://ci.appveyor.com/project/gaborcsardi/showimage)
[![](http://www.r-pkg.org/badges/version/showimage)](http://www.r-pkg.org/pkg/showimage)
[![CRAN RStudio mirror downloads](http://cranlogs.r-pkg.org/badges/showimage)](http://www.r-pkg.org/pkg/showimage)
[![Coverage Status](https://img.shields.io/codecov/c/github/r-lib/showimage/master.svg)](https://codecov.io/github/r-lib/showimage?branch=master)


Sometimes it is handy to be able to view an image file on an
R graphics device. This package just does that. Currently it supports
PNG files.

## Installation

```{r eval = FALSE}
devtools::install_github("r-lib/showimage")
```

## Usage

```{r results = "hide"}
library(showimage)
png(tmp <- tempfile(fileext = ".png"))
pairs(iris)
dev.off()
show_image(tmp)
```

## License

GPL-2 | GPL-3 © [Mango Solutions](https://github.com/mangothecat),
Simon Urbanek, [RStudio](https://github.com/rstudio)

Versions across snapshots

VersionRepositoryFileSize
1.0.0 2026-04-09 windows/windows R-4.5 showimage_1.0.0.zip 15.0 KiB

Dependencies (latest)

Imports

Suggests