Learn R Programming

⚠️There's a newer version (2.2) of this package.Take me there.

aqp (version 1.31)

Algorithms for Quantitative Pedology

Description

The Algorithms for Quantitative Pedology (AQP) project was started in 2009 to organize a loosely-related set of concepts and source code on the topic of soil profile visualization, aggregation, and classification into this package (aqp). Over the past 8 years, the project has grown into a suite of related R packages that enhance and simplify the quantitative analysis of soil profile data. Central to the AQP project is a new vocabulary of specialized functions and data structures that can accommodate the inherent complexity of soil profile information; freeing the scientist to focus on ideas rather than boilerplate data processing tasks . These functions and data structures have been extensively tested and documented, applied to projects involving hundreds of thousands of soil profiles, and deeply integrated into widely used tools such as SoilWeb . Components of the AQP project (aqp, soilDB, sharpshootR, soilReports packages) serve an important role in routine data analysis within the USDA-NRCS Soil Science Division. The AQP suite of R packages offer a convenient platform for bridging the gap between pedometric theory and practice.

Copy Link

Version

Install

install.packages('aqp')

Monthly Downloads

2,080

Version

1.31

License

GPL (>= 3)

Issues

Pull Requests

Stars

Forks

Maintainer

Dylan Beaudette

Last Published

August 19th, 2021

Functions in aqp (1.31)

ROSETTA.centroids

Average Hydraulic Parameters from the ROSETTA Model by USDA Soil Texture Class
HzDepthLogicSubset

Subset SoilProfileCollection Objects or Horizons via checkHzDepthLogic
SoilTextureLevels

Ranking Systems for USDS Soil Texture Classes
addDiagnosticBracket

Annotate Diagnostic Features
SoilProfileCollection

An S4 object representation of a group of soil profiles.
L1_profiles

Create Representative Soil Profiles via L1 Estimator
PMS2Munsell

Convert Pantone PMS codes to Munsell notation
addVolumeFraction

Symbolize Volume Fraction on a Soil Profile Collection Plot
addBracket

Add Depth Brackets
plotSPC

Create Soil Profile Sketches
argillic.clay.increase.depth

Return upper boundary of argillic horizon
aqp-package

Algorithms for Quantitative Pedology
aqp_df_class,SoilProfileCollection-method

Get aqp_df_class entry from metadata or return a safe value.
brierScore

Multinominal Brier Score
c,SoilProfileCollection-method

Combine SoilProfileCollection objects
depthWeights

Return a vector of contributing fractions over a depth interval
depthOf

Get top or bottom depths of horizons matching a regular expression pattern
bootstrapSoilTexture

Bootstrap Soil Texture Data
colorQuantiles

Soil Color Range via Quantiles
aggregateColor

Summarize Soil Colors
aggregateSoilDepth

Probabalistic Estimation of Soil Depth within Groups
checkHzDepthLogic

Check a SoilProfileCollection object for errors in horizon depths.
depth_units,SoilProfileCollection-method

Get depth units from metadata
equivalent_munsell

Indices of "equivalent" Munsell chips in the munsell data set
estimateAWC

Estimate available water capacity for fine-earth fraction
depths<-,SoilProfileCollection-method

Initialize a SoilProfileCollection from a data.frame object
findOverlap

Find Overlap within a Sequence
fillHzGaps

Find and Fill Horizon Gaps
as

Coerce SoilProfileCollection with as()
colorChart

Visualize soil colors in Munsell notation according to within-group frequency.
crit.clay.argillic

Determines threshold (minimum) clay content for argillic upper bound
fixOverlap

Fix Overlap within a Sequence via Simulated Annealing
denormalize

Create a (redundant) horizon-level attribute from a site-level attribute
getLastHorizonID

Get IDs of Deepest Horizons by Profile
generalize.hz

Generalize Horizon Names
alignTransect

Calculate Relative Positions from Transect Data
duplicate

Duplicte Profiles of a SoilProfileCollection
getSoilDepthClass

Generate Soil Depth Class Matrix
equivalentMunsellChips

Identify "equivalent" (whole number value/chroma) Munsell chips
.as.data.frame.aqp

Wrapper method for data.frame subclass conversion
contrastChart

Color Contrast Chart
checkSPC

Test for a valid SoilProfileCollection
.data_dots

Make a data.frame from non-standard expressions evaluated in a data environment
estimatePSCS

Estimate boundaries of the particle size control section (U.S Soil Taxonomy; 12th edition)
contrastClass

Soil Color Contrast
getClosestMunsellChip

Get Approximate Munsell Chip
getCambicBounds

Find all intervals that are potentially part of a Cambic horizon
ca630

Soil Data from the Central Sierra Nevada Region of California
estimateSoilDepth

Estimate Soil Depth
barron.torrent.redness.LAB

Barron & Torrent (1986) Redness Index in LAB color space
diagnostic_hz<-

Add data to the diagnostic slot
diagnostic_hz,SoilProfileCollection-method

Retrieve diagnostic data from SoilProfileCollection
hzDepthTests

Tests of horizon depth logic
allocate

Allocate soil properties within various classification systems.
colorContrast

Metrics of Contrast Suitable for Comparing Soil Colors
guessGenHzLevels

Guess Appropriate Ordering for Generalized Horizon Labels
colorContrastPlot

Color Contrast Plot
huePosition

Munsell Hue Position for Soil Color Description
hzdesgnname<-

Set horizon designation column name
hzDesgn,SoilProfileCollection-method

Get horizon designation column name
hzTransitionProbabilities

Horizon Transition Probabilities
guessHzDesgnName

Guess Horizon Designation Column Name
guessHzTexClName

Guess Horizon Texture Class Column Name
get.increase.depths

Return the horizon top depths from a call to get.increase.matrix()
get.increase.matrix

compute pair-wise distances to determine where an attribute increases within a vertical distance specified
.HSD

.HSD
getArgillicBounds

Estimate upper and lower boundary of argillic diagnostic subsurface horizon
compositeSPC

Return a list representation of site and horizon level data
dice

Efficient Slicing of SoilProfileCollection Objects
hztexclname<-

Set horizon texture class column name
get.ml.hz

Determine ML Horizon Boundaries
groupSPC

(EXPERIMENTAL) Store groupings within a profile collection.
.makeEquivalentMunsellLUT

.makeEquivalentMunsellLUT
hzID<-,SoilProfileCollection-method

Set horizon IDs
hzDistinctnessCodeToOffset

Convert Horizon Boundary Distinctness to Vertical Offset
munsell2rgb

Convert Munsell Color Notation to other Color Space Coordinates (sRGB and CIELAB)
plotColorMixture

Visualize Spectral Mixing of Munsell Colors
plotColorQuantiles

Visualize Color Quantiles
munsell.spectra

Spectral Library of Munsell Colors
.parseGrouped_formula

.parseHSD_formula
rgb2munsell

sRGB to Munsell Color Conversion
profile_id<-

Set profile IDs
getSurfaceHorizonDepth

Determine thickness of horizons (continuous from surface) matching a pattern
evalGenHZ

Evaluate Generalized Horizon Labels
harden.melanization

Harden (1982) Melanization
evalMissingData

Evaluate Missing Data
perturb

Perturb soil horizon depths using boundary distinctness
buntley.westin.index

Buntley-Westin (1965) Index
hzdesgnname,SoilProfileCollection-method

Get horizon designation column name
groupedProfilePlot

Grouped Soil Profile Plot
proj4string<-,SoilProfileCollection,ANY-method

Set PROJ4 string for the SoilProfileCollection
glom,SoilProfileCollection-method

Subset soil horizon data using a depth or depth interval
harden.rubification

Harden (1982) Rubification
missingDataGrid

Missing Data Grid
mollic.thickness.requirement

Calculate the minimum thickness requirement for Mollic epipedon
hzidname<-

Set horizon ID column name
correctAWC

Apply rock fragment or salt correction to available water content
sp1

Soil Profile Data Example 1
mixMunsell

Mix Munsell Colors via Spectral Library
munsell

Munsell to sRGB Lookup Table for Common Soil Colors
coordinates,SoilProfileCollection-method

Get coordinates from spatial slot
min,SoilProfileCollection-method

Get the minimum bottom depth in a SoilProfileCollection
metadata,SoilProfileCollection-method

Retrieve metadata from SoilProfileCollection
sp2

Honcut Creek Soil Profile Data
profileApply

Iterate over profiles in a SoilProfileCollection
profileGroupLabels

Soil Profile Group Labels
overlapMetrics

Find and Quantify Overlap within a 1D Sequence
hurst.redness

Hurst (1977) Redness Index
rowley2019

Soil Morphologic, Geochemical, and Mineralogy Data from Rowley et al. 2019.
panel.depth_function

Lattice Panel Function for Soil Profiles
names,SoilProfileCollection-method

Get names of columns in site and horizons table
hzTopographyCodeToLineType

Convert Horizon Boundary Topography to Line Type
resample.twotheta

Resample an XRD Pattern
confusionIndex

Confusion Index
restrictions<-

Add data to the restrictions slot
sim

DEPRECATED Simulate Soil Profiles
soilColorSignature

Soil Profile Color Signatures
repairMissingHzDepths

Repair Problematic Lower Horizon Depths
plotMultipleSPC

Plot Multiple SoilProfileCollection Objects
nrow,SoilProfileCollection-method

Get the number of horizons in a SoilProfileCollection
horizonNames<-

Set horizon column names
$

Get data from column of horizon or site data in a SoilProfileCollection
plot_distance_graph

Between Individual Distance Plot
hasDarkColors

Find horizons with colors darker than a Munsell hue, value, chroma threshold
replaceHorizons<-

Replace data in the horizon slot
random_profile

Random Profile
hzTopographyCodeToOffset

Convert Horizon Boundary Topography to Vertical Offset
subApply

Subset SPC based on result of performing function on each profile
parseMunsell

Parse Munsell Color Notation
pbindlist

Combine a list of SoilProfileCollection objects
unique,SoilProfileCollection-method

Uniqueness within a SoilProfileCollection via MD5 Hash
harmonize,SoilProfileCollection-method

Harmonize a property by profile-level denormalization for convenient visualization or analysis of ranges
idname,SoilProfileCollection-method

Get profile ID column name
[[<-

Add or change column of horizon or site data in a SoilProfileCollection
reorderHorizons

Re-order corrupted horizon data
segment

Segmenting of Soil Horizon Data by Depth Interval
[[

Get column of horizon or site data in a SoilProfileCollection
proj4string,SoilProfileCollection-method

Set PROJ4 string for the SoilProfileCollection
siteNames<-

Set site column names
slab-methods

Slab-Wise Aggregation of SoilProfileCollection Objects
restrictions,SoilProfileCollection-method

Retrieve restriction data from SoilProfileCollection
rruff.sample

Sample XRD Patterns
show

SoilProfileCollection show method
horizons,SoilProfileCollection-method

Retrieve horizon data from SoilProfileCollection
soil_minerals

Munsell Colors of Common Soil Minerals
mutate_profile

Transform a SPC (by profile) with a set of expressions
lunique

Eliminate duplicate instances of profile IDs in a list of SoilProfileCollections
invertLabelColor

Make High Contrast Label Colors
max,SoilProfileCollection-method

Get the maximum bottom depth in a SoilProfileCollection
simulateColor

Simulate Soil Colors
summarizeSPC

Perform summaries on groups (from group_by) and create new site or horizon level attributes
soilPalette

Soil Color Palette
spc2mpspline,SoilProfileCollection-method

Missing-data-safe, SPC-wide wrapper around mpspline2::mpspline "continuous" 1cm output
texcl_to_ssc

Textural conversions
spc_in_sync

Quickly assess relative state of site and horizon slots
xtableTauW

Format a LaTeX table with results
unroll

Unroll Genetic Horizons
subset,SoilProfileCollection-method

Subset a SoilProfileCollection with logical expressions
textureTriangleSummary

Soil Texture Low-RV-High as Defined by Quantiles
munsell2spc,SoilProfileCollection-method

Merge Munsell Hue, Value, Chroma converted to sRGB & CIELAB into a SoilProfileCollection
rebuildSPC

Rebuild a SoilProfileCollection object
shannonEntropy

Shannon Entropy
sp3

Soil Profile Data Example 3
[,SoilProfileCollection-method

Matrix/data.frame-like access to profiles and horizons in a SoilProfileCollection
pc

Numerical Soil Profile Comparison
site,SoilProfileCollection-method

Retrieve site data from SoilProfileCollection
sierraTransect

Soil Physical and Chemical Data Related to Studies in the Sierra Nevada Mountains, CA, USA.
explainPlotSPC

Visual Explanation for plotSPC
trunc,SoilProfileCollection-method

Truncate a SoilProfileCollection to specified top and bottom depth
transform,SoilProfileCollection-method

Transform a SPC with expressions based on site or horizon level attributes
tauW

Compute weighted naive and tau statistics for a cross-classification matrix
$<-

Set data in column of horizon or site data in a SoilProfileCollection
soiltexture

Lookup tables for sand, silt, clay, texture class, and textural modifiers.
jacobs2000

Soil Morphologic Data from Jacobs et al. 2002.
horizonColorIndices

Horizon Color Indices
f.noise

Example Objective Function for Full-Pattern Matching
guessHzAttrName

Guess Arbitrary Horizon Column Name
grepSPC

Subset SPC with pattern-matching for text-based attributes
thompson.bell.darkness

Thompson-Bell (1996) Index
glomApply

Subset an SPC by applying glom to each profile
sp6

Soil Physical and Chemical Data from Manganiferous Soils
hztexclname,SoilProfileCollection-method

Get horizon texture class column name
spec2Munsell

Convert reflectance spectra to closest Munsell chip
spectral.reference

Standard Illuminants and Observers
sp4

Soil Chemical Data from Serpentinitic Soils of California
us.state.soils

US State Soils
horizonDepths<-

Set horizon depth column names
length,SoilProfileCollection-method

Get the number of profiles in a SoilProfileCollection
pms.munsell.lut

Pantone Colors / Munsell Lookup Table
previewColors

Preview Colors
slicedHSD

Tukey's HSD Over Slices
split,SoilProfileCollection-method

Split a SoilProfileCollection object into a list of SoilProfileCollection objects.
splitLogicErrors

Split a SoilProfileCollection into a list based on types of horizon logic errors
subsetHz,SoilProfileCollection-method

Subset the horizons in a SoilProfileCollection using logical criteria
sp5

Sample Soil Database #5
subsetProfiles

DEPRECATED use subset
validSpatialData,SoilProfileCollection-method

Get names of columns in site table
traditionalColorNames

Traditional Soil Color Names
slice-methods

Slicing of SoilProfileCollection Objects