im3d-io: Read/Write calibrated 3D blocks of image data

im3d-ioR Documentation

Read/Write calibrated 3D blocks of image data

Description

Read/Write calibrated 3D blocks of image data

Usage

read.im3d(
  file,
  ReadData = TRUE,
  SimplifyAttributes = FALSE,
  ReadByteAsRaw = FALSE,
  ...
)

write.im3d(x, file, format = NULL, ...)

Arguments

file

Character vector describing a single file

ReadData

Whether to read the data itself or return metadata only. Default: TRUE

SimplifyAttributes

When TRUE leave only core im3d attributes.

ReadByteAsRaw

Whether to read byte values as R raw arrays. These occupy 1/4 memory but arithmetic is less convenient. (default: FALSE)

...

Arguments passed to methods

x

The image data to write (an im3d, or capable of being interpreted as such)

format

Character vector specifying an image format (e.g. "nrrd", "amiramesh"). Optional, since the format will normally be inferred from the file extension. See getformatwriter for details.

Details

Currently only nrrd and amira formats are implemented. Furthermore implementing a registry to allow extension to arbitrary formats remains a TODO item.

The core attributes of an im3d object are BoundingBox, origin, x, y , z where x, y, z are the locations of samples in the x, y and z image axes (which are assumed to be orthogonsl).

Value

For read.im3d an objecting inheriting from base array and im3d classes.

See Also

read.nrrd, read.amiramesh

write.nrrd, getformatwriter

Other im3d: as.im3d(), boundingbox(), im3d-coords, im3d(), imexpand.grid(), imslice(), is.im3d(), mask(), origin(), projection(), threshold(), unmask(), voxdims()

Examples

## Not run: 
# read attributes of vaa3d raw file
read.im3d("L1DS1_crop_straight.raw", ReadData = F, chan=2)

## End(Not run)

nat documentation built on May 29, 2024, 10:36 a.m.