
Convert an aqp SoilProfileCollection back to a list of PedonRecord
Source:R/aqp-interop.R
from_aqp.RdInverse of as_aqp. Walks each profile in the SPC,
renames aqp's canonical horizon column names back to soilKey's
(top -> top_cm, name -> designation,
clay -> clay_pct, ...), assembles a
PedonRecord per profile, and returns the list.
Value
A list of PedonRecord objects (length =
length(spc)).
See also
as_aqp, the forward conversion.
Examples
if (FALSE) { # \dontrun{
pedons <- list(make_ferralsol_canonical(), make_luvisol_canonical())
spc <- as_aqp(pedons)
pedons2 <- from_aqp(spc)
identical(pedons[[1]]$horizons$clay_pct, pedons2[[1]]$horizons$clay_pct)
#> [1] TRUE
} # }