hyperSpec object.read.ENVI(file = stop ("read.ENVI: file name needed"), header = NULL,
x = 0:1, y = x,
wavelength = NULL, label = NULL, log = NULL)NULL, the name of the
header file is guessed.initializehyperSpec object I experienced missing header files (or rather: header files
without any contents) produced by Bruker Opus' ENVI export.
In this case the necessary information can be given as a list in
parameter header instead. The elements of header are then:
header$ values meaning
samples integer no of columns / spectra in x direction
lines integer no of lines / spectra in y direction
bands integer no of wavelengths / data points per spectrum
`data type` format of the binary file
1 1 byte unsigned integer
2 2 byte signed integer
3 4 byte signed integer
4 4 byte float
5 8 byte double
9 16 (2 x 8) byte complex double
12 2 byte unsigned integer
`header offset` integer number of bytes to skip before
binary data starts
interleave directions of the data cube
"BSQ" band sequential (indexing: [sample, line, band])
"BIL" band interleave by line (indexing: [sample, line, band])
"BIP" band interleave by pixel (indexing: [band, line, sample])
`byte order` 0 or "little" little endian
1 or "big" big endian
"swap" swap byte order
}
Some more information that is not provided by the ENVI files may be
given:
Wavelength axis and axis labels in the respective parameters. For more
information, see initialize.
The spatial information is by default a sequence from 0 to
header$samples - 1 and header$lines - 1, respectively.
x and y give offset of the first spectrum and step size.
Thus, the object's $x colum is:
(0 : header$samples - 1) * x [2] + x [1].
The $y colum is calculated analogously.
read.ENVI:
Jarek Tuszynski (2008). caTools: Tools: moving window statistics,
GIF, Base64, ROC AUC, etc.. R package version 1.9.read.ENVI