amf_plot_datayear {amerifluxr}R Documentation

Plot data availability

Description

This function visualizes the BASE data availability for selected AmeriFlux sites, variables, and years. This is a wrapper around amf_list_data. However, it is strongly advised to subset the sites, variables, and/or years for faster processing and better visualization.

Usage

amf_plot_datayear(
  data_aval = NULL,
  site_set = NULL,
  var_set = NULL,
  nonfilled_only = TRUE,
  year_set = NULL
)

Arguments

data_aval

A data frame with at least five columns:

  • SITE_ID:

  • VARIABLE:

  • BASENAME: variable basename

  • GAP_FILLED

  • Y1990: Percentage of data availability in the year 1990 (0-1).

  • ...

If not specified, use amf_list_data by default.

site_set

A scalar or vector of character specifying the target AmeriFlux Site ID (CC-Sss). If not specified, it returns all sites.

var_set

A scalar or vector of character specifying the target variables as in basename. See AmeriFlux pagehttps://ameriflux.lbl.gov/data/aboutdata/data-variables/#base for a list of variable names. If not specified, it returns all variables.

nonfilled_only

Logical, whether only showing non-filled variables, or both non- and gap-filled variables. The default is TRUE.

year_set

A scalar or vector of integers. If not specified, it plots only years with any available data in selected sites and variables

Value

An object of class 'plotly' from heatmaply

See Also

amf_list_data, heatmaply

Examples

## Not run: 
# plot data availability for all variables at a single site
#  in all years
amf_plot_datayear(site_set = "US-CRT",
                  nonfilled_only = FALSE)

# plot data availability for non-filled FCH4 and WTD at all
#  sites in all years
amf_plot_datayear(var_set = c("FCH4", "WTD"),
                  nonfilled_only = TRUE)

# plot data availability for non-filled FCH4 at all sites
#  in 2018-2020
amf_plot_datayear(var_set = "FCH4",
                  year_set = c(2018:2020),
                  nonfilled_only = TRUE)

## End(Not run)

[Package amerifluxr version 1.0.0 Index]