itrax_radiograph: Read an Itrax Radiograph File

View source: R/itrax_radiograph.R

itrax_radiographR Documentation

Read an Itrax Radiograph File

Description

Reads an Itrax radiograph file and trims it according to the metadata provided.

Usage

itrax_radiograph(
  file = "radiograph.tif",
  meta = "document.txt",
  plot = FALSE,
  trim = TRUE
)

Arguments

file

defines the name of the datafile to parse

meta

defines the relating metadata

plot

would you like to create a plot as a side-effect?

trim

defines positions of the trim if required, input is a vector with min and max positions

Value

a matrix of RGB values, and the relevant data from the metadata file relating to the image. Also computes the aspect ratio of the image.

Examples

itrax_radiograph(file = system.file("extdata",
                         "CD166_19_S1_radiograph_adj.tif",
                         package = "itraxR",
                         mustWork = TRUE),
                 meta = system.file("extdata",
                         "CD166_19_S1_rad_document.txt",
                         package = "itraxR",
                         mustWork = TRUE),
                 plot = TRUE)


itraxR documentation built on July 26, 2023, 5:48 p.m.