| swrc_example | R Documentation |
A fully synthetic soil characterisation dataset generated to illustrate the functions in soilFlux. Its column layout follows the conventions common to soil characterisation databases (texture fractions, organic carbon, bulk density, standard depth intervals and matric-head points); van Genuchten curves are used to produce internally consistent water-content observations.
swrc_example
A data frame with 4 800 rows and 14 columns:
Character. Unique soil profile identifier
(e.g. "P0001").
Numeric. Total sand content (%).
Numeric. Silt content (%).
Numeric. Clay content (%).
Numeric. Soil organic carbon (%).
Numeric. Bulk density (g/cm3).
Numeric. Very fine sand fraction (%).
Numeric. Fine sand fraction (%).
Numeric. Medium sand fraction (%).
Numeric. Coarse sand fraction (%).
Numeric. Matric head (cm H2O, positive).
Numeric. Volumetric water content (m3/m3).
Approximately 1% of values are NA to simulate missing
measurements.
Character. Depth interval (e.g. "0-5", "5-15",
etc.).
Character. USDA texture class (one of: Sand, Loamy Sand, Sandy Loam, Loam, Silt Loam, Clay Loam, Clay).
No third-party or institutional data are included in or distributed
with this package. Every value in swrc_example is generated by
data-raw/create_example_data.R from set.seed(2025) and is exactly
reproducible by re-running that script.
The dataset contains 120 unique profiles (PEDON_ID) across five
depth intervals (0–5, 5–15, 15–30, 30–60, 60–100 cm) and eight
matric-head points per depth (pF approximately 0, 1, 1.5, 2, 2.5, 3, 4.2, 7).
Profiles are evenly distributed across seven USDA texture classes.
Water-content observations were generated with the van Genuchten (1980) equation using parameters that vary realistically with texture and depth, then small Gaussian noise was added.
Synthetic dataset generated by
data-raw/create_example_data.R.
van Genuchten, M. T. (1980). A closed-form equation for predicting the hydraulic conductivity of unsaturated soils. Soil Science Society of America Journal, 44(5), 892–898.
data("swrc_example")
head(swrc_example)
table(swrc_example$Texture[!duplicated(swrc_example$PEDON_ID)])
# Prepare for modelling
df <- prepare_swrc_data(swrc_example, depth_col = "depth")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.