Generate a color signature for each soil profile in a collection.
soilColorSignature(spc, r = "r", g = "g", b = "b", method='colorBucket', RescaleLightnessBy = 1, useProportions=TRUE, pigmentNames=c('.white.pigment', '.red.pigment', '.green.pigment', '.yellow.pigment', '.blue.pigment'))
SoilProfileCollection objectdetails pending...
For the `colorBucket` method, a data.frame object containing:
idname(spc)Column names can be adjusted with the pigmentNames argument.
For the `depthSlices` method ...
For the `pam` method ...
https://en.wikipedia.org/wiki/Lab_color_space
# trivial example, not very interesting data(sp1) depths(sp1) <- id ~ top + bottom # convert Munsell -> sRGB triplets rgb.data <- munsell2rgb(sp1$hue, sp1$value, sp1$chroma, return_triplets = TRUE) sp1$r <- rgb.data$r sp1$g <- rgb.data$g sp1$b <- rgb.data$b # extract color signature pig <- soilColorSignature(sp1)