Estimate the soil depth of a single profile within a SoilProfileCollection object.
estimateSoilDepth(f, name = "hzname", top = "hzdept", bottom = "hzdepb", p = 'Cr|R|Cd', no.contact.depth = NULL, no.contact.assigned = NULL)
a single integer, the soil depth
getSoilDepthClass, profileApply
data(sp1) depths(sp1) <- id ~ top + bottom # apply to each profile in a collection, and save as site-level attribute sp1$depth <- profileApply(sp1, estimateSoilDepth, name='name', top='top', bottom='bottom') ## Not run: ------------------------------------ # # sample data # data(gopheridge, package='soilDB') # # # run on a single profile # estimateSoilDepth(gopheridge[1, ]) # # # apply to an entire collection # profileApply(gopheridge, estimateSoilDepth) ## ---------------------------------------------