MyNixOS website logo
Description

Compute Soil Carbon Fluxes for the National Ecological Observatory Network Sites.

Acquires and synthesizes soil carbon fluxes at sites located in the National Ecological Observatory Network (NEON). Provides flux estimates and associated uncertainty as well as key environmental measurements (soil water, temperature, CO2 concentration) that are used to compute soil fluxes.

neonSoilFlux

neonSoilFlux is a repository code to acquire, tidy, and compute soil respiration fluxes at NEON sites using the flux-gradient method.

Installation

Installation in R through:

  • CRAN: install.packages("neonSoilFlux")
  • Github using the devtools package:
devtools::install_github("jmzobitz/neonSoilFlux", 
                          build = TRUE, 
                          build_opts = c("--no-resave-data", "--no-manual"),
                          force=TRUE
                          )

If you encounter problems with code in this repository, feel free to post an issue.

Usage

To analyze fluxes once the package is installed requires a two step process:

  1. Get an API token from NEON. Instructions on how to do that are here: https://www.neonscience.org/resources/learning-hub/tutorials/api-token-setup.

  2. Set your API token in your local R environment:

neonSoilFlux::neon_api_token("YOUR_TOKEN_HERE", install = TRUE)

Then your token will be saved automatically when downloading data from NEON.

  1. First acquire the NEON data, following conventions of loadByProduct function in the neonUtilities package. We will use the data located at the San Joaquin Experimental Range terrestrial site and compute fluxes from June 2022. You can also consult NEON's map of all sites to explore data from a terrestrial site of your choosing.
library(tidyverse)  # Make sure dplyr, purrr, and lubridate are installed
library(neonUtilities)  # Used for acquiring NEON data
library(neonSoilFlux)

out_env_data <- acquire_neon_data(site_name = 'SJER',
                  download_date = '2022-06'
                  )

What will be returned is a nested list containing site_data (monthly variables needed to compute fluxes) and site_megapit (soil properties)

  1. Next process and compute fluxes at this site:

out_fluxes <- compute_neon_flux(input_site_env = out_env_data$site_data,
                  input_site_megapit = out_env_data$site_megapit
                  )

You now have a data frame of computed fluxes.

More detailed usage information is given in the vignette using-neonSoilFlux (vignette(using-neonSoilFlux)).

Credits & Acknowledgements

The package neonSoilFlux was funded with support from the National Science Foundation, grant #2017829. Any opinions, findings, and conclusions or recommendations expressed in this material are those of the author(s) and do not necessarily reflect the views of the National Science Foundation.

The National Ecological Observatory Network is a program sponsored by the National Science Foundation and operated under cooperative agreement by Battelle. This material is based in part upon work supported by the National Science Foundation through the NEON Program.

Code Contributions / Changelog:

  • (pre-2021): Initial code developed by Edward Ayres ([email protected])
  • 2021: Initial package development and testing by Zobitz and undergraduate researchers Lajntxiag Lee and Kathleen O'Rourke (both Augsburg University)
  • 2022: Ongoing refinement and testing by undergraduate researchers at the following institutions:
    • Ridwan Abdi, Kebba Janeh, Nevin Lor, Diana Ortiz Alvarracin, Dijone Mehmeti, Ali Musa, Barbara Sabino Pina, Ly Xiong, Xeng Yang (Augsburg University)
    • Courtney Leung (Northwestern University)
  • 2024: Refinement to include a gapfilling routine from Zoey Werbin at Boston University as well as additional calculations of the soil flux via different approaches in Maier, M., and H. Schack-Kirchner. 2014. “Using the Gradient Method to Determine Soil Gas Flux: A Review.” Agricultural and Forest Meteorology 192–193 (July): 78–95. https://doi.org/10.1016/j.agrformet.2014.03.006.
  • 05.2024 Renaming of pacakge to neonSoilFlux from NEONSoils and associated updates to prepare for CRAN submission.
  • 11.2025 Update to improve efficiency and to coincide with publications of neonSoilFlux: An R Package for Continuous Sensor-Based Estimation of Soil CO~2~ Fluxes, published in Methods in Ecology and Evolution
  • 06.2026 Update (V4.0.0) to include NEON API token support.

License

GNU Affero General Public License Version 3, 19 November 2007

Disclaimer

Information and documents contained within this repository are available as-is. Codes or documents, or their use, may not be supported or maintained under any program or service and may not be compatible with data currently available from the NEON Data Portal.

R-CMD-check

Metadata

Version

4.0.1

License

Unknown

Platforms (79)

    Darwin
    FreeBSD
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    uefi
    wasip1
    Windows
Show all
  • aarch64-darwin
  • aarch64-freebsd
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64-uefi
  • aarch64-windows
  • aarch64_be-none
  • arc-linux
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-freebsd
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-linux
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • sh4-linux
  • vc4-none
  • wasm32-wasip1
  • wasm64-wasip1
  • x86_64-cygwin
  • x86_64-freebsd
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-uefi
  • x86_64-windows