Learn R Programming

⚠️There's a newer version (0.100.2) of this package.Take me there.

hyperSpec (version 0.98-20120713)

Interface for hyperspectral data, i.e. spectra + meta info (spatial, time, concentration, ...)

Description

This package is an interface to handle hyperspectral data sets in R. I.e. spatially or time-resolved spectra, or spectra with any other kind of information associated with each of the spectra. The spectra can be data as obtained in XRF, UV/VIS, Fluorescence, AES, NIR, IR, Raman, NMR, MS, etc. More generally, any data that is recorded over a discretized variable, e.g. absorbance = f (wavelength), stored as a vector of absorbance values for discrete wavelengths is suitable.

Copy Link

Version

Install

install.packages('hyperSpec')

Monthly Downloads

1,454

Version

0.98-20120713

License

GPL (>= 3)

Maintainer

Claudia Beleites

Last Published

July 14th, 2012

Functions in hyperSpec (0.98-20120713)

ncol

The Number of Rows (Spectra), Columns, and Data Points per Spectrum of an hyperSpec Object)
sample

Random Samples and Permutations Take a sample of the specified size from the elements of x with or without replacement.
decomposition

Convert Principal Component Decomposition or the like into a hyperSpec Object Decomposition of the spectra matrix is a common procedure in chemometrix data analysis. decomposition converts the result matrices into new hyperSpec objects.
wl2i

Conversion between Wavelength and Spectra Matrix Column Index wl2i returns the column indices for the spectra matrix for the given wavelengths. i2wl converts column indices into wavelengths.
aggregate

aggregate hyperSpec objects
mean_sd

Mean and Standard Deviation Calculate mean and standard deviation, and mean, mean $\pm$ one standard deviation, respectively.
[

Extract and Replace parts of hyperSpec objects
legendright

Plot multivariate data into colour channels
plotspc

Plotting Spectra Plot the spectra of a hyperSpec object, i.e. intensity over wavelength. Instead of the intensity values of the spectra matrix summary values calculated from these may be used.
all.equal

Comparison of hyperSpec objects
hy.unittest

hyperSpec unit tests If svUnit is available, run the unit tests and display the results.
normalize01

Normalize numbers -> [0, 1]
barbiturates

Barbiturates Spectra from .spc example files A time series of mass spectra in a list of hyperSpec objects.
initialize

Creating a hyperSpec Object Like other S4 objects, a hyperSpec object can be created by new. The hyperSpec object is then initialized using the given parameters.
pearson.dist

Distance based on Pearson's $R^2$
.DollarNames.hyperSpec

command line completion for $
plotmat

Plot spectra matrix
makeraster

makeraster
read.txt.long

Import and Export of hyperSpec objects Besides save and load, two general ways to import and export data into hyperSpec objects exist.
rbind.fill.matrix

Bind matrices by row, and fill missing columns with NA
sweep

vanderMonde

Function evaluation on hyperSpec objects
Math2

Math Functions for hyperSpec Objects
qplotmixmap

qplotmap with colour mixing for multivariate overlay
seq.hyperSpec

Sequence generation along spectra or wavelengths This function generates sequences along the spectra (rows) or wavelengths of hyperSpec objects.
merge

Merge hyperSpec objects
hy.getOptions

Options for package hyperSpec Functions to access and set hyperSpec's options.
spc.NA.linapprox

Impute missing data points
wl

Getting and Setting the Wavelength Axis wl returns the wavelength axis, wl<- sets it.
bind

plotc

Calibration- and Timeseries Plots, Depth-Profiles and the like plotc plots intensities of a hyperSpec object over another dimension such as concentration, time, or a spatial coordinate.
split

Split a hyperSpec object according to groups split divides the hyperSpec object into a list of hyperSpec objects according to the groups given by f.
Arith

Arithmetical Operators: +, -, *, /, ^, %%, %/%, %*%
chondro

Raman spectra of 2 Chondrocytes in Cartilage A Raman-map (laterally resolved Raman spectra) of chondrocytes in cartilage.
flu

Quinine Fluorescence Spectra Fluorescence spectra of different dilutions of quinine forming a calibration set.
cov

Covariance matrices for hyperSpec objects
logbook

Logging the processing ot a hyperSpec Object Extracts the slot @log of a hyperSpec object.
sel.poly

Interactively select a polygon (grid graphics)
subset

subset
read.spc.KaiserMap

read.spc.KaiserMap imports sets of .spc files of Raman maps written by Kaiser Optical Systems' Hologram software. It may also serve as an example how to write wrapper functions for read.spc to conveniently import specialized sets of .spc files.
read.jdx.Shimadzu

JCAMP-DX Import for Shimadzu Library Spectra
scan.txt.Witec

File Import Witec Raman
orderwl

Sorting the Wavelengths of a hyperSpec Object Rearranges the hyperSpec object so that the wavelength vector is in increasing (or decreasing) order.
logentry

Append a Row to the logbook of a hyperSpec Object A log entry is generated and appended to the log of x.
qplotmap

Spectra plotting with ggplot2
wl.eval

Evaluate function on wavelengths of hyperSpec object
labels<-

Get and Set Labels of a hyperSpec Object value may be a list or vector of labels giving the new label for each of the entries specified by which.
paracetamol

Paracetamol Spectrum A Raman spectrum of a paracetamol tablet.
collapse

Collapse hyperSpec objects
apply

apply Computes summary statistics for the spectra of a hyperSpec object.
empty

Empty hyperSpec object
hyperSpec-package

Package hyperSpec
laser

Laser Emission A time series of an unstable laser emission.
as.data.frame

Conversion of a hyperSpec object into a data.frame or matrix as.data.frame returns x@data (as data.frame) as.matrix returns the spectra matrix x@data$spc as matrix
spc.fit.poly

Polynomial Baseline Fitting These functions fit polynomal baselines.
chk.hy

Validation of hyperSpec objects
colSums

functions for hyperSpec objects
hyperSpec-class

Class "hyperSpec"
qplotc

Spectra plotting with ggplot2
qplotspc

Spectra plotting with ggplot2
read.txt.Shimadzu

Reads Shimadzu Spectra Files (.txt) as exported by Shimadzu Chrome Solution (v. 2.73)
spc.bin

Wavelength Binning In order to reduce the spectral resolution and thus gain signal to noise ratio or to reduce the dimensionality of the spectral data set, the spectral resolution can be reduced.
as.character

Convert a hyerSpec object to character strings for Display print, show, and summary show the result of as.character.
spc.loess

read.ENVI.Nicolet

Nicolet uses some more keywords in their header file. read.ENVI.Nicolet therefore appends "description", "z plot titles", and "pixel size" to keys.hdr2log before calling read.ENVI. They are then interpreted as follows: ll{ description giving the position of the first spectrum z plot titles wavelength and intensity axis units, comma separated pixel size interpreted as x and y step size }
wc

wc word count of ASCII files
map.sel.poly

Interactively select a polygon (grid graphics) and highlight points
quickdf

Quick data frame. Experimental version of as.data.frame that converts a list to a data frame, but doesn't do any checks to make sure it's a valid format. Much faster.
dimnames

Dimnames for hyperSpec objects
plotmap

Plot a Map and Identify/Select Spectra in the Map levelplot functions for hyperSpec objects. An image or map of a summary value of each spectrum is plotted. Spectra may be identified by mouse click.
mark.dendrogram

plot-methods

Plotting hyperSpec Objects
matlab.palette

Matlab-like Palettes Two palettes going from blue over green to red, approximately as the standard palette of Matlab does. The second one has darker green values and is better suited for plotting lines on white background.
scan.txt.Renishaw

import Raman measurements from Renishaw ASCII-files import Raman measurements from Renishaw (possibly compressed) .txt file.
spc.identify

trellis.factor.key

Color coding legend for factors Modifies a list of lattice arguments (as for levelplot, etc.) according to the factor levels. The colorkey will shows all levels (including unused), and the drawing colors will be set accordingly.
Summary

The functions