plot_eddy: Plot Time Series of Eddy Covariance Data

Description Usage Arguments Details Modules Quality Control Gap-filling and NEE separation Abbreviations See Also

Description

Visualize flux measurements together with micrometeorological or other related variables in monthly and weekly intervals. Missing values, scales of axes and plotting regions are treated in an automated way.

Usage

1
2
3
4
5
plot_eddy(x, flux, qc_flag = "none", test = "none", flux_gf = "none",
  NEE_sep = FALSE, skip = c("none", "monthly", "weekly"),
  panel_top = c("t_light", "vpd_rn", "h_err_var"),
  panel_bottom = c("vpd_rn", "t_light", "h_err_var"), light = c("ppfd",
  "rg"), GPP_check = TRUE, document = TRUE, mad_adj_lims = FALSE)

Arguments

x

A data frame with column names representing required variables. See 'Details' below.

flux

A character string. Specifies the column name in x with flux values.

qc_flag

A character string. Specifies the column name in x with flux related quality control flag used for visualisation of data quality and setting of y-axis range. If "none" is provided, all data will be used. See 'Quality Control'.

test

A character string. Specifies the column name in x with quality control flag for visualisation of its effect on the data. If "none" is provided, no visualisation will be done. See 'Quality Control'.

flux_gf

A character string. Specifies the column name in x with gap-filled flux values.

NEE_sep

A logical value. Determines whether NEE separation should be visualized. If TRUE, columns "Reco" and "GPP" are expected in x.

skip

A character string. Determines whether plotting should be done in monthly (skip = "weekly"), weekly intervals (skip = "monthly") or both (skip = "none").

panel_top

A character string. Selects one of the available modules for plotting additional variables. This module is displayed above the panel with fluxes in weekly plots. Can be abbreviated. See 'Modules'.

panel_bottom

A character string. Selects one of the available modules for plotting additional variables. This module is displayed below the panel with fluxes in weekly plots. Can be abbreviated. See 'Modules'.

light

A character string. Required only for the "T_light" module. Selects preferred variable for incoming light intensity. "PAR" or "GR" is allowed. Can be abbreviated.

GPP_check

A logical value. If TRUE, column "GPP" is checked to be of the same sign convention as "NEE" column and corrected in the case it is not. Required only if NEE_sep = TRUE.

document

A logical value. If TRUE, values of qc_flag and test arguments are documented in both monthly and weekly plots.

Details

The data frame x is expected to have certain properties. It is required that it contains column named "timestamp" of class "POSIXt" with regular sequence of date-time values, typically with (half-)hourly frequency. Any missing values in "timestamp" are not allowed. Thus, if no records exist for given date-time value, it still has to be included. It also has to contain required (depends on the argument values and applied modules) column names. If required auxiliary variable is not available (e.g. "P", "T"), it still has to be included in x as a named column with NA values. The x column defined by argument flux is the only one that has to contain at least one non-missing value.

If skip = "weekly", minimum requirements for x column names are "timestamp" and flux. If skip = "none" or "monthly", "P" and respective names specified in 'Modules' (see below) are also required.

Variable names for plot labels are extracted from required column names of x. Units are extracted from x if they are present as units attributes of required columns. If missing, "-" string is used instead.

Plotting is separated into two stages. Firstly, flux time-series data are drawn in monthly intervals. Monthly plotting regions consist of four figures on top of each other representing separately four consecutive months. Secondly, if skip = "none" or "monthly", flux time-series data are drawn together with auxiliary data in weekly intervals. Weekly plotting regions are described in 'Modules' section (see below).

Modules

Applies only if skip = "none" or "monthly". Plotting in weekly intervals is simplified by using predefined modules. Their main purpose is to achieve well-arranged display of auxiliary variables. Weekly plotting regions consist of two figures representing separately two consecutive weeks. Each figure contains three panels on top of each other. The middle panel always contains the values from flux and "P" columns of x. Variables used in the upper and lower panel can be changed by panel_top and panel_bottom. These arguments specify the respective modules that will be loaded (can be the same) and thus also a certain set of required column names of x (variables).

Available modules are:

Quality Control

qc_flag and test relate to QC flags available for the specified flux. Only QC scheme using QC flag range 0 - 2 is supported.

Flags specified by qc_flag separate corresponding flux values to two groups. Used data for flags 0 and 1 (black points) and Excluded data for flags 2 and NA (grey points). The range of y-axis limit in the figures with flux values is based on Used data only. If qc_flag = "none", all data are Used data. The time interval used for setting the range is one month both for monthly (respective month) and weekly (month centered on the respective week) plots.

In order to emphasize flux values with lower quality, test can be specified. Values with QC flag = 1 have green center of the point. Values with QC flag = 2 or NA have red center of the point.

NB: flux data with NA values are always Excluded data and cannot be emphasized (NA values are not drawn).

Gap-filling and NEE separation

Gap-filled flux values can be displayed using flux_gf as a line overlaying the flux values. If NEE_sep = TRUE, columns "Reco" and "GPP" are expected in x. GPP_check is evaluated only if NEE_sep = TRUE. If GPP_check = TRUE, mean GPP is checked to be negative so it compares well with NEE and corrected accordingly if needed. Thus negative values denote carbon sink. Such test can fail for measurements above surfaces without vegetation or ecosystems with insignificant sink. In that case set GPP_check = FALSE and check and correct GPP sign convention manually.

Abbreviations

See Also

read_eddy and strptime_eddy.


grahamstewart12/tidyflux documentation built on June 4, 2019, 7:44 a.m.