Unlimited learning, half price | 50% off

Last chance! 50% off unlimited learning

Sale ends in


soilDB (version 2.8.8)

get_site_data_from_NASIS_db: Get Site Data from a local NASIS Database

Description

Get site-level data from a local NASIS database.

Usage

get_site_data_from_NASIS_db(
  SS = TRUE,
  include_pedon = TRUE,
  nullFragsAreZero = TRUE,
  stringsAsFactors = NULL,
  dsn = NULL
)

Value

A data.frame

Arguments

SS

fetch data from Selected Set in NASIS or from the entire local database (default: TRUE)

include_pedon

Include pedon and transect data joined to site? (default: TRUE)

nullFragsAreZero

should surface fragment cover percentages of NULL be interpreted as 0? (default: TRUE)

stringsAsFactors

deprecated

dsn

Optional: path to local SQLite database containing NASIS table structure; default: NULL

Author

Jay M. Skovlin and Dylan E. Beaudette

Details

It is possible to have multiple pedon records per site observation and multiple site observations per site, which will result in multiple records per site. See argument include_pedon=FALSE to omit joins to pedon and transect tables.

The following aggregations of child table information are performed by this function:

  • Site Area Overlap for State, County and MLRA are returned for related area records, as specified in the site table, as the following column names: site_state, site_county, and site_mlra.

  • Site Observation Surface Fragment data are simplified (converted to wide format) using simplifyFragmentData().

  • The best Ecological Site History record is selected using get_ecosite_history_from_NASIS_db(best = TRUE).

  • Site Other Vegetation Class information is aggregated by class name, using " & " as the separator when multiple classes are assigned.

  • When multiple Site Bedrock entries are present, only the shallowest is returned by this function. In lieu of bedrock depth the first record in the table is returned.

See Also

get_hz_data_from_NASIS_db(), fetchNASIS(), fetchVegdata()