goFlux, For User-Friendly Chamber Data Processing, Flux Estimation, and Diagnostics
One Package to rule them all
Non-steady state (static) chambers are widely used for measuring soil greenhouse gas (GHG) fluxes, such as CO2, CH4, N2O, NH3, CO, and water vapor (H2O). While linear regression (LM) is commonly used to estimate GHG fluxes, this method tends to underestimate the pre-deployment flux (f0). Indeed, non-linearity is expected when the gas concentration increases or decreases inside a closed chamber, due to changes in gas gradients between the soil and the air inside the chamber. In addition, lateral gas flow and leakage contribute to non-linearity. Many alternative to LM have been developed to try to provide a more accurate estimation of f0, for instance the method of Hutchinson and Mosier[1] (HM), which was implemented in the HMR
package by Pedersen et al. (2010)[2]. However, non-linear models have a tendency to largely overestimate some flux measurements, due to an exaggerated curvature. Therefore, the user is expected to decide which method is more appropriate for each flux estimate. With the advent of portable greenhouse gas analyzers (e.g. Los Gatos Research (ABB) laser gas analyzers), soil GHG fluxes have become much easier to measure, and more efficient ways to calculate these flux estimates are needed in order to process large amounts of data. A recent approach was developed by HĂĽppi et al. (2018)[3] to restrict the curvature in the HM model for a more reliable flux estimate. In the HM model, the curvature is controlled by the kappa parameter, \(\kappa\). HĂĽppi et al.[3] suggest the use of the KAPPA.MAX
to limit the maximal curvature allowed in the model (see their R package gasfluxes
, available on the CRAN). This procedure introduces less arbitrary decisions in the flux estimation process.
Previous software developed to calculate GHG fluxes are limited in many aspects that the goFlux package is meant to overcome. Most are limited to the linear regression approach (e.g. Flux Puppy, and the R packages flux
and FluxCalR
), others do not include data pre-processing (e.g. the R packages HMR
, flux
and gasfluxes
), or if they do, they are compatible with only a few designated systems (e.g. Flux Puppy and FluxCalR
), and none include an automatic selection of the best flux estimate (LM or HM) based on objective criteria, except the R packages gasfluxes
and HMR
.
This new R package, goFlux
is meant to be “student proof”, meaning that no extensive knowledge or experience is needed to import raw data into R, choose the best model to calculate fluxes (LM or HM), quality check the results objectively and obtain high quality flux estimates. The package contains a wide range of functions that allows the user to import raw data from a variety of instruments (LI-COR, LGR, GAIA2TECH, Gasmet, Picarro, Aeris and PP-Systems); calculate fluxes from a variety of GHG (CO2, CH4, N2O, NH3, CO and H2O) with both linear (LM) and non-linear (HM) flux calculation methods; align instruments clocks after data import; interactively identify measurements (start and end time) if there are no automatic chamber recordings (e.g. LI-COR smart chamber); plot measurements for easy visual inspection; and quality check the measurements based on objective criteria.
Three R packages for the Elven-kings under the CRAN,
Seven for the Dwarf-lords in their halls of open software,
Nine for Mortal Men doomed to write scripts themselves,
One for the Dark Lady on her dark throne
In the Land of GitHub where the Shadows lie.
One Package to rule them all, One Package to find them,
One Package to bring them all and in the darkness bind them
In the Land of GitHub where the Shadows lie.
Analysis workflow
This package will help you import raw data into R, identify measurements, calculate fluxes, select the best flux estimate (LM or HM), save the results as RData or Excel spreadsheet, and visually inspect the results on plots that can be saved as pdf.
Click on the tabs on the sidebar to navigate through each step, or follow the links in the table of contents below.
How to cite
Please cite this R package using this publication in JOSS:
Rheault et al., (2024). goFlux: A user-friendly way to calculate GHG fluxes yourself, regardless of user experience. Journal of Open Source Software, 9(96), 6393, https://doi.org/10.21105/joss.06393
JOSSCast
Wanna know more about how goFlux came to be?
Watch my interview on JOSSCast with Abigail Cabunoc Mayes & Arfon Smith, from the Journal of Open Source Software, on Spotify, Youtube or Apple Podcasts 👇
Episode highlights:
- [02:03] - Karelle’s Journey to Creating goFlux
- [02:56] - Understanding Greenhouse Gas Fluxes
- [05:19] - Measurement Techniques and Tools
- [09:30] - Challenges and Advantages of goFlux
- [20:20] - Open Source Contributions and Community Support
- [23:57] - Karelle’s Experience with JOSS
- [27:00] - Future Plans and Contributions
- [28:59] - Organizing the Community and Setting Standards
- [31:27] - Conclusion and Farewell
Acknowledgements
This software development was supported by the SilvaNova project funded by the NOVO Nordisk Foundation (grant no. NNF20OC0059948).