siWlg: Reduce Number of Wavelengths

View source: R/gen_general.r

siWlgR Documentation

Reduce Number of Wavelengths

Description

Reduces the number of wavelengths in a provided dataset, either by simply keeping only the wavelengths of the 12 or 15 water matrix coordinates in the first overtone (1300nm - 1600nm), or by providing a user-defined list containing the wavelengths to be kept.

Usage

siWlg(dataset, avg = FALSE, wlg = "ot1.12")

Arguments

dataset

The standard dataset as produced by gfd.

avg

Logical If, for further reduction of wavelengths, the values of the wavelengths in each group (as defined in each row of the matrix) should be averaged.

wlg

List or character. Provide an integer matrix with two columns and n rows to keep the ranges of wavelengths defined in each row - see examples. Provide either ot1.12 or ot1.15 to only keep the respective wavelengths of the 12 or 15 water matrix coordinates in the first overtone. (The definition of the wavelengths is in root of the package aquap2.)

Value

The transformed dataset.

See Also

selectWls, siWl

Other Classification Helpers: classification_helpers

Other Extract Elements: getHeader(), getWavelengths,aquap_data-method, getcd(), getcm(), siWl()

Other Helper Functions: ap2_settings_setup(), ap2dme(), export_ap2_ToXlsx(), export_header_toXls(), genFolderStr(), genNoiseRecExp(), genTempCalibExp(), getcd(), getcm(), getstn(), printStdColnames(), reColor(), saveAQdata(), updateSettings()

Examples

## Not run: 
fd <- gfd()
m <- matrix(c(300, 320, 400, 450, 530, 570), ncol=2, byrow=TRUE)
fdc <- siWlg(fd, wlg=m) 
fdc <- siWlg(fd) # using all the 12 wavelength ranges in the first overtone
fdc <- siWlg(fd, TRUE) # averaging within the 12 ranges, resulting in only 12
# wavelengths in the dataset

## End(Not run)

bpollner/aquap2 documentation built on March 29, 2024, 7:33 a.m.