hs_SCAdiss: Calculate the spectral contrast angle (SCA) between all cells...

Description Usage Arguments Value References Examples

View source: R/hs_SCAdiss.R

Description

The SCA measures the angle between two vectors corresponding to closely related spectra to measure whether they are the same or not (Wan *et al.* 2002). This function returns a dist object based on the SCA for downstream processing.

Usage

1

Arguments

x

a hyperSpec object containing the cells in the rows, and wavenumbers (features) in columns

Value

a distance object containing the SCA between each cell

References

Wan, K. X., Vidavsky, I., & Gross, M. L. (2002). Comparing similar spectra: from similarity index to spectral contrast angle. Journal of the American Society for Mass Spectrometry, 13(1), 85-88.

Examples

1
2
3
4
5
6
7
8
# Load hyperSpec object
data("hs_example")

# Convert to MassSpectrum object
hs.x.proc <- hs_preprocess(hs_example)

# cluster cells
disst <- hs_SCAdiss(hs.x.proc)

CMET-UGent/MicroRaman documentation built on July 25, 2020, 6:20 p.m.