From 9c3af4e0120cb6d70d6b7b5beac3d54df2ea069a Mon Sep 17 00:00:00 2001 From: Andrew Gene Brown Date: Tue, 25 Jun 2024 12:17:23 -0700 Subject: [PATCH] Fix new `hz_to_taxpartsize()` example for metadata updates in #309 --- R/allocate.R | 5 +++++ man/hz_to_taxpartsize.Rd | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/R/allocate.R b/R/allocate.R index 037b8305..7a8eabcc 100644 --- a/R/allocate.R +++ b/R/allocate.R @@ -697,6 +697,11 @@ allocate <- function(..., to = c("FAO Salt Severity", "FAO Black Soil", "ST Diag #' #' depths(h) <- id ~ top + bottom #' +#' # set required metadata for estimatePSCS() +#' hzdesgnname(h) <- "hzname" +#' hztexclname(h) <- "texcl" +#' hzmetaname(h, "clay") <- "clay" +#' #' pscs <- data.frame(id = h$id, rbind(estimatePSCS(h))) #' names(pscs)[2:3] <- c("top", "bottom") #' diff --git a/man/hz_to_taxpartsize.Rd b/man/hz_to_taxpartsize.Rd index 2daefdf8..0e40c149 100644 --- a/man/hz_to_taxpartsize.Rd +++ b/man/hz_to_taxpartsize.Rd @@ -69,6 +69,11 @@ fragvoltot = h$frags depths(h) <- id ~ top + bottom +# set required metadata for estimatePSCS() +hzdesgnname(h) <- "hzname" +hztexclname(h) <- "texcl" +hzmetaname(h, "clay") <- "clay" + pscs <- data.frame(id = h$id, rbind(estimatePSCS(h))) names(pscs)[2:3] <- c("top", "bottom")