Learn R Programming

fwtraits for retrieving from www.freshwaterecology.info database

Aim of the package

fwtraits provides a seamless and robust access to the species ecological parameters, traits, or indicators from the www.freshwaterecology.info database (Schmidt-Kloiber & Hering 2015). The database hosts an array of ecological parameters for different taxonomic groups, including fish, macroinvertebrates, phytoplankton, diatoms, and phytobenthos. Experts periodically review the data to ensure quality. The data is used in ecological studies, primarily for functional diversity or macroecological analyses.

NOTE

  • To seamlessly access the databases, an API has been developed by the database hosts. Therefore, to freely access the database, the user is required to sign up and make a request for the API key.

Package installation

To access the package:

# install.packages("devtools")

if (!requireNamespace("remotes", quietly = TRUE)) install.packages("remotes")

remotes::install_github("AnthonyBasooma/fwtraits")

#To access the package vignettes in RStudio using vignettes function.
remotes::install_github("AnthonyBasooma/fwtraits", build_vignettes = TRUE, dependencies = TRUE)

Package usage


The database is arranged into organism groups including macroinvertebrates, fishes, phytoplankton, macrophytes, and phytobenthos most especially the diatoms (Figure 1). The package is a wrapper around the fweapi2 developed and maintained by the University of Natural Resources and Life Sciences (BOKU), Vienna, Austria.

Before using the package, the user is strongly advised to run the fw_be4ustart() to get the steps required to access and use the package in accessing the species ecological parameters, traits or indicators.

Main functions

  • fw_setapikey() for securing API key in the user R environment.
  • fw_searchdata() To allow get data from the database. However, this is mostly an internal function since the data is not already parsed to enable usability.
  • fw_fetchdata() is the main function that provides all the parameters for data access. The function is wrapped around fw_searchdata() function to allow the user to easily get and manipulate the data during package usage.

Other utility functions

  • check_names() to check spellings species taxonomic names to allow the user obtain the species traits.
  • fw_checktraits()harmonize species traits to allow effective between user inputs and database information.
  • fw_visualize()provides graphical display of the information obtained from the database.

Funding

The package was created with support from the AquaINFRA project which is aimed at developing data and services to support marine and freshwater scientists and stakeholders. Also, the DANUBE4All project and HR21 Doctoral School under BOKU University provided logistical support during the development of this package.

References

Schmidt-Kloiber, A., & Hering, D. (2015). Www.freshwaterecology.info - An online tool that unifies, standardises and codifies more than 20,000 European freshwater organisms and their ecological preferences. Ecological Indicators, 53, 271-282. https://doi.org/10.1016/j.ecolind.2015.02.007

Copy Link

Version

Install

install.packages('fwtraits')

Monthly Downloads

158

Version

1.0.0

License

GPL (>= 3)

Issues

Pull Requests

Stars

Forks

Maintainer

Anthony Basooma

Last Published

November 11th, 2025

Functions in fwtraits (1.0.0)

pbenthodata

Taxonomic data for the phytobentho species in www.freshwaterecology.info database.
speciesdata

Efiplus data used to develop ecological sensitivity parameters for riverine species in European streams and rivers.
invertbackbone

Taxonomic data for species in the freshwaterecology.info database
checktrait

Checks the traits spelling compared to user input.
classifydata

Data with ecological parameters classification.
fw_cite

Get database citations
fw_dbguide

Standard table with taxonomic groups and their traits explanations.
fw_fdendro

For computing the functional dendogram
check_packages

Check for packages to install and respond to use
clean_names

Check and clean species names to match standard names in the database.
fuzzy_codes

Internal package and create dummy codes
fw_fdcompute

Compute the functional diversity indices and community weighted means.
fw_be4ustart

Steps to follow in using the Freshwater Information Platform
fw_keyload

For loading the API key from the environment.
fw_fetchdata

Extracting the traits from the downloaded data.
fw_setapikey

Function and instructions creating the API_KEY variable in the User environment.
fw_geosites

Auto generation of species sites
fw_register

Open the registration page
fw_visualize

ggplot2 visualization.
fw_token

Access and loading the token key
fw_paramlist

Function to retrieve all the traits in the database.
fw_searchdata

To download data from the Freshwaterecology.info database.