The Soil Texture Wizard
Page content: In short | Introduction | Installation | Text based graphical user interface | List of classification systems implemented | Acknowledgements (contributors) | Other works and software on soil textures (triangles) | Articles related to soil texture triangles or systems | See also (other R projects)
Last update: 2017/03/29
The text below is not up to date.
soiltexture
is a package (extension) for
the R, a free software environment for statistical
computing and graphics.
soiltexture
is a toolbox for plotting, classifying and
transforming soil texture data (clay,
silt and sand contents).
Soil texture data and soil texture classifications systems
are traditionally visualised (plotted) on ternary diagrams
(called texture plots, texture diagrams or texture triangles).
soiltexture
currently implements 17 soil texture
classification systems from all around the world. See
here for a gallery of available texture
triangles, and see also the package vignette (after
installing the package):
vignette( "soiltexture_vignette" )
See above for an on-line version of this vignette / tutorial.
You need to install beforehand the sofware R (“a free software environment for statistical computing and graphics”).
From R homepage, go to the CRAN homepage or (better) choose the nearest CRAN mirror.
From there, choose 'Download R for …' (Windows, Mac or Linux), and then choose 'base' or 'install R for the First time'.
From there (latest stable R release), download the software installation files (if you are running on Windows) and install the program on your computer (follow the instructions from the installer).
Note: Unless you know what you are doing, it is recommended
to install the latest R release (it may not always be possible
to install the package soiltexture
on older versions of R,
or some of the latest features might be missing).
Open R, and type the command:
install.packages( "soiltexture" )
Note: This will only work with the latest (stable) version
of R. You should also check on the package R-forge page
that the “Build status” of soiltexture
is “Current” (and not
“Failed to build”).
Open R, and type the command:
install.packages("soiltexture", repos="http://R-Forge.R-project.org")
Note: It can take some days before r-forge
updates its
system to the latest R stable version (after a new stable
release). You can check what version of R is used by clicking
on “Show/Hide extra info” on the package R-forge page,
and then checking “Windows binary” or “Source package”. The
R version currently used on r-forge
should appear there.
The GitHub mirror of soiltexture (Notice
that I am not the maintainer of this page) makes it possible
to use devtools
package installation method to install the
development version of the package soiltexture
. It can be
an interesting solution when using a version of R that is
different from the one installed on r-forge
(newer or older).
Follow the instructions given on devtools GitHub page. See in particular “Updating to the latest version of devtools”.
Open R and type:
devtools::install_github("rforge/soiltexture/pkg/soiltexture")
Notice that you can install in the same way the package
soiltexturetransformation
by Wei Shangguan:
devtools::install_github("rforge/soiltexture/pkg/soiltexturetransformation")
For technical reason this package does not compile on r-forge
(because of a dependency on drc
that used to be on r-forge
but is now developed outside of r-forge
).
From version 1.3.0
the package soil texture comes along
with a simple text-based graphical user interface.
After you have installed R
and the package
soiltexture
, simply start R and type:
soiltexture::soiltexture_gui()
This will start the text-based graphical user interface. You will be asked a series of simple question (4 to 8. With a list of possible answers), to import soil texture data, visualise it on a texture triangle and classify the texture data according to a classification system. Without typing any other commands than the one above. You can also display an empty texture triangle (without data-points) and/or display a texture triangle without classification system.
More information on how to prepare your soil texture data can be found on the function help page. In R, type:
help( "soiltexture_gui" )
or simply
?soiltexture_gui
Note: An alternative way to call soiltexture_gui
is to type:
library( "soiltexture" )
soiltexture_gui()
Below is a list of texture triangles implemented in the package, together with their 'code' in the package.
HYPRES.TT
.USDA.TT
,FR.AISNE.TT
.FR.GEPPA.TT
.DE.BK94.TT
.DE.SEA74.TT
. DE.TGL85.TT
. UK.SSEW.TT
.AU2.TT
.BE.TT
.CA.FR.TT
(in French) or CA.EN.TT
(in English). ISSS.TT
.ROM.TT
. PL.TT
.BRASIL.TT
.SiBCS13.TT
. USDA1911
.Many of the texture classification systems listed above wouldn't have been implemented without the contribution of the following people (contributors of the package):
They contributed to make soiltexture
a useful tool for many
soil scientists, and to make the specifications of these texture
triangles available in an open-source format.
Numerous other works and software exist that deal with soil textures and soil textures triangles. Nevertheless, to my knowledge, The Soil Texture Wizard is the only tool that offers an integrated set of functionalities for soil textures (smart graphs + classification + multi-triangle + multi-geometry).
triangle.plot
and triangle.biplot
functions, from the
R package ADE4, by Daniel Chessel, Anne-Beatrice Dufour
and Stephane Dray. These functions are not specialised in
soil textures plots (and can not plot soil texture classes),
but offer of nice “zoom” feature that don't exist in The
Soil Texture Wizard, nor in the PLOTRIX
package (see
below). For illustrations, see the web-page on
triangle.plot on “R Graphical Manual”
(by Osamu Ogasawara).
ternaryplot
function in the R package VCD by David
Meyer, Achim Zeileis and Kurt Hornik. For illustrations,
see the web-page on ternaryplot on “R Graphical Manual”.
The functions soil.texture
and soil.texture.uk
from
the R package plotrix, by Jim Lemon et al.. It allows
to create graphs, with or without soil textures data,
following the USDA or the UK soil texture triangles. There
is also an underlying ternary plot function that can be
used without soil texture classes. It is nevertheless not
possible to project the triangles into another geometry,
nor to transform or classify soil textures data. The R
functions presented here (soiltexture
) are originally
derived from some functions of the plotrix package.
For illustrations of plotrix, see the web-page on
soil.texture and soil.texture.uk on “R Graphical
Manual”.
If you are fond of the package ggplot2, you may like the package ggtern that implements elegant ternary diagrams and texture triangle (USDA) in a ggplot2 fashion. Note: The package seems to have been archived from CRAN and is thus not available (2015/04/14).
Texture Autolookup, by Christopher Teh Boon Sung is a standalone program, with a graphical user interface, that can classify soil textures following the USDA, UK, Canadian, FAO texture triangles, or 7 other systems. The work has been published in two articles of “Communications in Soil and Plant Analysis”, in 1996 and 2003. The software also allows to plot soil texture data in 2 different triangle geometries.
TRIANGLE, “A Program For Soil Textural Classification”, by Aris Gerakis and Brian Baer allows to classify soil textures data after the USDA soil texture triangle (published in the Soil Science Society of America Journal in 1999. The article is available here).
r.soils.texture is a Grass-GIS add-on for classifying raster files of soil textures with 3 classification systems (USDA, FAO, ISSS). Note that this is not R code.
Richer de Forges A., Feller C., Jamagne M. & Arrouays D., 2008. Perdus dans le triangle des textures, Études et Gestion des Sols, 15:2, pp. 97-111. En: “Lost in the textures triangle”. The authors are presenting a gallery of 29 soil textures triangles, either still in use nowadays or that were used in the past, from France and other countries, and comparing the location of soil texture triangles limits between several triangles. The article also presents a table comparing the particle size limits (for clay, silt and sand fractions) between numerous countries.
Minasny B. and McBratney. A.B., 2001. The australian soil texture boomerang: a comparison of the australian and usda/fao soil particle-size classication systems. Australian Journal of Soil Research, 39:1443-1451.
Nemes A., Wösten J.H.M., Lilly A., and Oude Voshaar J.H.,
Other projects exists that provides useful soil-related R functions (toolboxes for the pedometrician):
aqp. 'Algorithms for Quantitative Pedology'.
soilwater. Provides soil water retention functions and soil hydraulic conductivity functions and pedotransfer functions to estimate their parameter from easily available soil properties.
Other packages that may interest soil scientists are: