Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

seriesExtent

Retrieve Soil Series Extent Maps from SoilWeb


Description

This function downloads a generalized representations of a soil series extent from SoilWeb, derived from the current SSURGO snapshot. Data can be returned as vector outlines (SpatialPolygonsDataFrame object) or gridded representation of area proportion falling within 800m cells (raster object). Gridded series extent data are only available in CONUS. Vector representations are returned with a GCS/WGS84 coordinate reference system and raster representations are returned with an Albers Equal Area / NAD83 coordinate reference system (EPSG 6350).

Usage

seriesExtent(s, type = c("vector", "raster"), timeout = 60)

Arguments

s

a soil series name, case-insensitive

type

series extent representation, vector results in a SpatialPolygonsDataFrame object and raster results in a raster object

timeout

time that we are willing to wait for a response, in seconds

Note

This function requires the rgdal package.

Author(s)

D.E. Beaudette

References

Examples

if(requireNamespace("curl") &
   curl::has_internet()) {
  
  # required packages
  library(sp)
  library(raster)
  library(rgdal)
  
  # specify a soil series name
  s <- 'magnor'
  
  # return as SpatialPolygonsDataFrame
  x <- seriesExtent(s, type = 'vector')
  # return as raster
  y <- seriesExtent(s, type = 'raster')
  
  # note that CRS are different
  proj4string(x)
  projection(y)
  
  # transform vector representation to CRS of raster
  x <- spTransform(x, CRS(projection(y)))
  
  # graphical comparison
  par(mar = c(1, 1 , 1, 3))
  plot(y, axes = FALSE)
  plot(x, add = TRUE)
  
  
}

soilDB

Soil Database Interface

v2.6.1
GPL (>= 3)
Authors
Dylan Beaudette [aut], Jay Skovlin [aut], Stephen Roecker [aut], Andrew Brown [aut, cre]
Initial release
2021-04-7

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.