Subset the horizons in a SoilProfileCollection using logical criteria

# S4 method for SoilProfileCollection
subsetHz(x, ...)

Arguments

x

a SoilProfileCollection

...

Comma-separated set of R expressions that evaluate as TRUE or FALSE in context of horizon data frame. Length for individual expressions matches number of horizons, in x.

Value

a SoilProfileCollection with a subset of horizons, possibly with some sites removed

Examples


data(sp3)

depths(sp3) <- id ~ top + bottom

# show just horizons with 10YR hues
plot(subsetHz(sp3, hue == '10YR'))