spectra2rgb

Convert hyperspectral reflectance signatures to sRGB hex codes and CIE Lab* colour coordinates, using the CIE 1931 2-degree standard observer and the D65 standard illuminant.

Developed for leaf-level plant phenotyping data from the PSI PlantScreen platform, but applicable to any reflectance spectra in the 400-700 nm range.

Installation

# devtools::install_github("jelguerat/spectra2rgb")
install.packages("spectra2rgb", repos = c('https://jelguerat.r-universe.dev', 'https://cloud.r-project.org'))

Citation

If you use spectra2rgb in published work, please cite:

Elguera, J. (2026). spectra2rgb: Convert spectral signatures to sRGB and CIELAB colour coordinates (Version 0.1.0) [Computer software]. Zenodo. https://doi.org/10.5281/zenodo.23255917

License

GPL (>= 3)