Learn R Programming

tidyspec (version 0.1.0)

spec_norm_var: Standardize Spectral Data to Unit Variance

Description

This function standardizes the numeric spectral data in each column to have a mean of 0 and a standard deviation of 1 (unit variance), while preserving the wavelength column.

Usage

spec_norm_var(.data, wn_col = NULL)

Value

A `tibble` with the standardized spectral data, containing the wavelength column and the standardized numeric columns.

Arguments

.data

A `data.frame` or `tibble` containing spectral data.

wn_col

A character string specifying the column name for the wavelength data. Default is `"Wn"`.