View source: R/spectrace_calculate_quantities.R
spectrace_calculate_quantities | R Documentation |
This function calculates selected optical quantities from the calibrated spectrace data. Spectral irradiance is interpolated to desired resolution. CCT is calculated with McCamy's approximation.
spectrace_calculate_quantities(
lightData,
quantities = c("ALL", "sc", "mc", "lc", "mel", "rod", "scEDI", "mcEDI", "lcEDI",
"melEDI", "rodEDI", "scELR", "mcELR", "lcELR", "melELR", "rodELR", "scDER", "mcDER",
"lcDER", "melDER", "rodDER", "cie1924_v2_lux", "cie2008_v2_lux", "cie2008_v10_lux",
"CCT", "cie1931_XYZ", "cie1931_x", "cie1931_y", "cie1964_x", "cie1964_y", "CLA",
"CS"),
resolution = c("5nm", "1nm"),
interp_method = c("pchip", "linear", "none"),
keep_spectral_data = TRUE
)
lightData |
Data frame containing the calibrated light data. |
quantities |
Quantities to be calculated. Can be any or multiple of: ("ALL", "sc", "mc", "lc", "mel", "rod", "scEDI", "mcEDI", "lcEDI", "melEDI", "rodEDI", "scELR", "mcELR", "lcELR", "melELR", "rodELR", "scDER", "mcDER", "lcDER", "melDER", "rodDER", "cie1924_v2_lux", "cie2008_v2_lux", "cie2008_v10_lux", "CCT", "cie1931_x", "cie1931_y", "cie1931_XYZ", "cie1964_x", "cie1964_y", "CLA", "CS"). If "ALL" (the default), all quantities will be calculated and added to the data frame. |
resolution |
String specifying the resolution of the output spectrum. Can be "5nm" (default) or "1nm". |
interp_method |
Method for interpolation. Can be "pchip" (smooth piecewise hermetic interpolation), "linear", or "none". Defaults to "pchip". |
keep_spectral_data |
Logical. Should the spectral irradiance columns be kept? Defaults to TRUE. |
Data frame extended with specified quantities.
If keep_spectral_data
is FALSE then the spectral data columns will be
removed from the original data frame.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.