gather_species_inventory: Convert species inventory data into tall, tidy data frame

gather_species_inventoryR Documentation

Convert species inventory data into tall, tidy data frame

Description

Given species inventory data create a tall format data frame usable by other terradactyl functions.

Usage

gather_species_inventory_terradat(
  dsn = NULL,
  tblSpecRichDetail = NULL,
  tblSpecRichHeader = NULL
)

species_count(species_inventory_tall, ...)

tall_species(species_inventory_detail)

gather_species_inventory_lmf(dsn = NULL, file_type = "gdb", PLANTCENSUS = NULL)

gather_species_inventory(
  dsn = NULL,
  source,
  tblSpecRichDetail = NULL,
  tblSpecRichHeader = NULL,
  PLANTCENSUS = NULL,
  file_type = "gdb"
)

Arguments

dsn

Character string. The full filepath and filename (including file extension) of the geodatabase containing the table of interest. This field is unnecessary if you supply either both of tblSpecRichDetail and tblSpecRichHeader (AIM/DIMA/TerrADat) or PLANTCENSUS (LMF/NRI).

tblSpecRichDetail

Dataframe of the data structure tblSpecRichDetail from the DIMA database with the addition of PrimaryKey and DBKey fields. Use with tblSpecRichHeader when data source is AIM, DIMA, or TerrADat; alternately provide dsn.

tblSpecRichHeader

Dataframe of the data structure tblSpecRichHeader from the DIMA database with the addition of PrimaryKey and DBKey fields. Use with tblSpecRichDetail when data source is AIM, DIMA, or TerrADat; alternately provide dsn.

PLANTCENSUS

Dataframe of the data structure PLANTCENSUS from LMF/NRI database with the addition of PrimaryKey and DBKey fields. Use when data source is LMF or NRI; alternately provide dsn.

source

Character string. The data source format, "AIM", "TerrADat", "DIMA", "LMF", "NRI" (case independent).

Value

A tall data frame containing species inventory data.

See Also

Other <gather>: gather_all(), gather_gap(), gather_height(), gather_lpi(), gather_plot_characterization(), gather_rangeland_health(), gather_soil_horizon(), gather_soil_stability(), gather_soil_summary()

Examples

gather_species_inventory(dsn = "Path/To/AIM_Geodatabase.gdb",
                         source = "AIM")
gather_species_inventory(dsn = "Path/To/LMF_Geodatabase.gdb",
                         source = "LMF")

aim_specrichdetail <- read.csv("Path/To/tblSpecRichDetail.csv")
aim_specrichheader <- read.csv("Path/To/tblSpecRichHeader.csv")
gather_species_inventory(source = "AIM",
                         tblSpecRichDetail = aim_specrichdetail,
                         tblSpecRichHeader = aim_specrichheader)

lmf_census <- read.csv("Path/To/PLANTCENSUS.csv")
gather_species_inventory(source = "LMF",
                         PLANTCENSUS = lmf_census)

smccord/terradactyl documentation built on Dec. 1, 2023, 7:37 p.m.