get_md: Metadata file management

Description Usage Arguments Details Value Warning Note Author(s) References See Also Examples

View source: R/get_md.R

Description

Returns the input files required by EddyPro software (LI-COR registered trademark; Fratini and Mauder, 2014).

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
get_md(path_ecmd = NULL,
       path_rawdata = NULL,
       path_output = NULL,
       online,
       path_sa_file = NULL,
       path_pf_file = NULL,
       tlag_meth,
       despike_meth=c("None", "VM97", "M13"),
       detrend_meth=c("BA", "LD"),
       tilt_correction_meth=c("DR", "PF"))

Arguments

path_ecmd

path where the CC-Xxx_ecmd.csv file containing metadata information is stored.

path_rawdata

path where eddy covariance rawdata files are stored.

path_output

path where the results of eddypro_run will be stored (it will be created, if any).

online

logical. Indicating whether the parameters of the planar fit method and the spectral correction factors are taken from results of previous processing (online=TRUE) or estimated by using the current set of EC rawdata (online=FALSE).

path_sa_file

path where the spectral assessment file generated by EddyPro software is stored.

path_pf_file

path where the planar fit file generated by EddyPro software is stored.

tlag_meth

time lag detection method: 0 None; 1 Constant time lag, 2 Maximum covariance with default; 3 Maximum covariance; 4 Automatic optimization.

despike_meth

despiking method: "None", not apply; "VM97", algorithm by Vickers and Mahrt (1997); "M13", algorithm by Mauder et al (2013).

detrend_meth

trend removal method: "BA" Block Average; "LD" Linear Detrending (Rannik and Vesala, 2001).

tilt_correction_meth

axis rotation method for tilt correction: "DR" Double Rotation; "PF" Planar Fit (Wilczak et al, 2001).

Details

This function builds the input files required by EddyPro software to process eddy covariance rawdata files.

Value

Returns the following files

CC-Xxx.eddypro
CC-Xxx.metadata
CC-Xxx_dynamic_metadata.txt

where CC-Xxx denoting the site's ID.

Warning

If online=FALSE, the number of rawdata needs to be large enough to allow robust estimates of the planar fit parameters (Wilczak et al 2001) and of the spectral correction factors (Fratini et al, 2012). In case of few rawdata, the double rotation method for sonic anemometer tilt correction and the analytical method by Moncrieff et al (1997) for spectral correction will be performed.

Note

Rawdata must be provided as .csv file with the following name: CC-Xxx????yyyymmddHHMM????.csv, where CC-Xxx is the site's ID, yyyymmddHHMM is the ISO timestamp, and ?s denoting free characters. For example: DE-HoH_EC_201901010030_v01.csv.

Author(s)

Domenico Vitale, Dario Papale

References

Fratini, G., Mauder, M. (2014). Towards a consistent eddy-covariance processing: an intercomparison of EddyPro and TK3. Atmospheric Measurement Techniques, 7(7), 2273-2281, doi: https://doi.org/10.5194/amt-7-2273-2014.

Fratini, G., Ibrom, A., Arriga, N., Burba, G., Papale, D. (2012). Relative humidity effects on water vapour fluxes measured with closed-path eddy-covariance systems with short sampling lines. Agricultural and forest meteorology, 165, pp 53-63, doi: https://doi.org/10.1016/j.agrformet.2012.05.018.

LI-COR Biosciences: EddyPro 7.0.4: Help and User's Guide, LI-COR Biosciences, Lincoln, Nebraska USA, www.licor.com/EddyPro, 2019.

Mauder, M., Cuntz, M., Drue, C., Graf, A., Rebmann, C., Schmid, H. P., ..., Steinbrecher, R. (2013). A strategy for quality and uncertainty assessment of long-term eddy-covariance measurements. Agricultural and Forest Meteorology, 169, 122-135, doi: https://doi.org/10.1016/j.agrformet.2012.09.006.

Moncrieff, J. B., Massheder, J. M., De Bruin, H., Elbers, J., Friborg, T., Heusinkveld, B., ..., Verhoef, A. (1997). A system to measure surface fluxes of momentum, sensible heat, water vapour and carbon dioxide. Journal of Hydrology, 188, 589-611, doi: https://doi.org/10.1016/S0022-1694(96)03194-0.

Rannik, U., Vesala, T. (1999). Autoregressive filtering versus linear detrending in estimation of fluxes by the eddy covariance method. Boundary-Layer Meteorology, 91(2), 259-280, doi: https://doi.org/10.1023/A:1001840416858.

Vickers, D., Mahrt, L. (1997). Quality control and flux sampling problems for tower and aircraft data. Journal of atmospheric and oceanic technology, 14(3), 512-526, doi: https://doi.org/10.1175/1520-0426(1997)014<0512:QCAFSP>2.0.CO;2.

Wilczak, J.M., Oncley, S.P., Stage, S.A. (2001). Sonic anemometer tilt correction algorithms. Boundary-Layer Meteorology, 99(1), 127-150, doi: https://doi.org/10.1023/A:1018966204465.

See Also

closed_path_rawdata

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
## Not run: 
workdir <- getwd()
siteID <- "DE-HoH"
PATH_ECMD <- system.file("extdata", "DE-HoH_ecmd.csv", package = "RFlux")
PATH_RAWDATA <- system.file("extdata", package = "RFlux")
PATH_OUTPUT <- paste0(workdir, "/eddypro/processing")
PATH_SA_FILE <- system.file("extdata", "spectral_assessment.txt", package = "RFlux")
PATH_PF_FILE <- system.file("extdata", "planar_fit.txt", package = "RFlux")

MD <- get_md(path_ecmd=PATH_ECMD,
             path_rawdata=PATH_RAWDATA,
             path_output=PATH_OUTPUT,
             online=TRUE,
             path_sa_file=PATH_SA_FILE,
             path_pf_file=PATH_PF_FILE,
             tlag_meth=2,
             despike_meth="VM97",
             detrend_meth="BA",
             tilt_correction_meth="PF")
             
## End(Not run)

domvit81/RFlux documentation built on Nov. 20, 2019, 8:02 a.m.