Griebel20_budgets: Compute Griebel et al. (2020) budgets

View source: R/Summarizing.R

Griebel20_budgetsR Documentation

Compute Griebel et al. (2020) budgets

Description

Yearly budgets with different consideration of space-time equity.

Usage

Griebel20_budgets(
  df,
  TimestampCol = "TIMESTAMP_START",
  wdCol = "WD",
  targetCol = "NEE_VUT_REF",
  QcCol = "NEE_VUT_REF_QC",
  interval = 1800L,
  flux = c("carbon", "energy"),
  nInt = 8L,
  year = NULL,
  NEE_scor = TRUE,
  GPP_scor = FALSE,
  normalize = TRUE
)

Arguments

df

A data frame.

TimestampCol

A character string. Specifies a column name in df that carries date-time information either in POSIXt or text strings of format "%Y%m%d%H%M". Date-time information is expected to represent either start or middle of the averaging period.

wdCol

A character string. Specifies a column name in df that carries the wind direction in degrees.

targetCol

A character string. Specifies a column name in df that carries the flux values for budget computations.

QcCol

A character string or NULL. Specifies a column name in df that carries gap-filling quality flags of targetCol variable. It is assumed that df[, QcCol] == 0 identifies the measured (not gap-filled) records of targetCol variable. If NULL, all non-missing values of targetCol are used for budgeting.

interval

An integer value. Represents an extent of eddy covariance averaging period in seconds (e.g. 1800 for 30 mins, 3600 for 60 mins).

flux

A character string. What type of flux does targetCol represent? Can be abbreviated.

nInt

An integer value. A number of wind sectors and time intervals for binning.

year

An integer vector. If NULL, budgets are produced for all years available in df. Otherwise only specified years are processed.

NEE_scor, GPP_scor

A logical value. Should sign correction of NEE (GPP) be performed?

normalize

A logical value. If TRUE (default), space and space-time equitable budgets are corrected for the missing number of records in a year.

Details

The function produces several variants of budgets that represent annual sums of measured and quality checked flux with different consideration of space-time equity. In order to obtain budgets in sensible units after summation, appropriate flux type must be specified. E.g. conversion factor for carbon fluxes (umol(CO2) m-2 s-1 -> g(C) m-2 s-1) is 12.0107e-6, conversion factor for energy fluxes (W m-2 -> MJ m-2 s-1) is 1e-6. Temporal aspect of the conversion is handled based on interval extent.

Available variants of budgets include Traditional budget (uncorrected sum of measured fluxes), Standardized budget (corrected according to wind sector climatology based on all observation years), Space-equitable budget (each sector contributes the exact same amount to budget) and Space-time-equitable budget (each sector contributes equally to budget and sector contributions are made time-uniform). Computation is generalized for any number of nInt and any extent of interval. Please notice that Traditional budget and Standardized budget differ only if multiple years are used for computation. The reliability of the results depends on the data availability within each year. For details see References.

Arguments specifying df column names represent FLUXNET standard. To process REddyProc outputs, timestamp must be corrected to represent middle of averaging period and appropriate columns selected (see Examples).

Value

A data frame with columns corresponding to year, different types of budgets and number of observations used for budget computation each year. Each column has assigned attributes varnames and units.

Sign Correction

Although common sign convention for measured NEE (Net Ecosystem Exchange) denotes negative fluxes as CO2 uptake, summed NEE is typically reported with the opposite sign convention and is assumed to converge to NEP (Net Ecosystem Production), especially over longer aggregation intervals. In case of GPP (Gross Primary Production), REddyProc package applies sign convention denoting positive fluxes as carbon sink, thus sign correction before summing is not needed.

Since there is no reliable way to guess the sign convention used in the data set, NEE_scor and GPP_scor must be specified. The default values (NEE_scor = TRUE; GPP_scor = FALSE) are adapted to sign convention applied in REddyProc package.

References

Griebel, A., Metzen, D., Pendall, E., Burba, G., & Metzger, S. (2020). Generating spatially robust carbon budgets from flux tower observations. Geophysical Research Letters, 47, e2019GL085942. https://doi.org/10.1029/2019GL085942

See Also

spti_boot and spti_coverage.

Examples

## Not run: 
library(REddyProc)

# convert timestamp
DETha98 <- fConvertTimeToPosix(Example_DETha98, 'YDH', Year = 'Year',
Day = 'DoY', Hour = 'Hour')[-(2:4)]

# generate randomly wind directions for demonstration purposes (not included)
DETha98$WD <- sample(0:359, nrow(DETha98), replace = TRUE)

# if QcCol = NULL, all non-missing values of targetCol are used for budgeting
not_filled <- DETha98
not_filled$DateTime <- not_filled$DateTime - 900
Griebel20_budgets(not_filled, "DateTime", "WD", "LE", NULL, flux = "energy")

# gap-filling is not needed but illustrates processing of FLUXNET data
# notice that ustar filtering of NEE should be applied before budgeting
DETha98 <- filterLongRuns(DETha98, "NEE")
EProc <- sEddyProc$new('DE-Tha', DETha98,
c('NEE', 'Rg', 'Tair', 'VPD', 'Ustar'))
EProc$sMDSGapFillAfterUstar('NEE', uStarTh = 0.3, FillAll = TRUE)
filled <- cbind(DETha98, EProc$sExportResults())

# correct timestamp to represent middle of averaging period
filled$DateTime <- filled$DateTime - 900
Griebel20_budgets(filled, "DateTime", "WD", "NEE", "NEE_uStar_fqc")

## End(Not run)


lsigut/openeddy documentation built on Aug. 5, 2023, 12:25 a.m.