At this time you must install the tidyFIA
package via GitHub.
remotes::install_github("SilviaTerra/tidyFIA")
The main function is tidy_fia
which will import the specified tables from FIADB that correspond to an area of interest represented by a geospatial object in R (class sf
) or a list of state abbreviations (e.g. c("CA", "NV")
).
To get started you can simply run this example command to get the FIA tables for the state of Minnesota:
mn_data <- tidyFIA::tidy_fia(
states = "MN",
postgis = TRUE
)
SilviaTerra is hosting the FIADB data in a PostGIS database. Please reach out to Henry Rodman if you would like the password for the database. Alternatively you can ask tidy_fia
to download and import the data directly from the CSVs stored at the FIA datamart by setting the parameter postgis
to FALSE
. This is slower than querying the database but will work without any authentication.
The example will import these tables by default:
"plot", "subplot", "cond", "tree", "survey"
Each table is an element in the list mn_data
.
To use one of the tables you call them like this:
mn_data[["plot"]]
mn_data[["tree"]]
...