% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/benchmark-lucas-2018.R
\name{.fill_horizon_from_soilgrids}
\alias{.fill_horizon_from_soilgrids}
\title{Fill a horizon (or synthesise a new one) from SoilGrids 250m}
\usage{
.fill_horizon_from_soilgrids(
  pedon,
  horizon_idx,
  properties,
  soilgrids_depth = "0-5cm",
  horizon_top_cm = 0,
  horizon_bottom_cm = 20,
  horizon_designation = "Ap",
  lookup_fn = lookup_soilgrids
)
}
\description{
Internal helper used by \code{\link{benchmark_lucas_2018}}. For
each requested property, calls \code{lookup_fn} (default
\code{\link{lookup_soilgrids}}) at \code{soilgrids_depth},
converts to the soilKey unit and writes onto the pedon's horizon
\code{horizon_idx} via \code{add_measurement(...,
source = "inferred_prior")}. Synthesises the horizon if it does
not exist yet (geometry from \code{horizon_top_cm} /
\code{horizon_bottom_cm}).
}
\details{
Test injection: pass \code{lookup_fn = function(...) value} to
bypass the network when unit-testing.
}
\keyword{internal}
