Last data update: 2014.03.03

R: Calibration of "hour" parameters for temperature...
par_calibrationR Documentation

Calibration of "hour" parameters for temperature interpolation

Description

Calibrates the monthly parameters for the definition of the interpolation algorithm values of: time of minimum temperature; time of maximum temperature; time of sunset; parameter 'c' (see references for details). It works on more than one series at once. It also calculates an average calibration table, for simulations of series with no calibration.

Usage

  par_calibration(meas, date.format = "ymd",
    cal_period = NULL, missing_value_code = NA,
    min_valid_yrs = 1, band_min = 4:9, band_max = 12:16,
    band_suns = 14:20, silent = FALSE, aver_series = NULL)

Arguments

meas

measured hourly values file (table), where the first column is the series' ID

date.format

date format in meas. Default is "ymd" (year month day)

cal_period

calibration period for the series. Default is NULL (use whole period)

missing_value_code

allows to deal missing data if a code (either numeric or character) is passed. Default is NA

min_valid_yrs

minimum fraction of year(s) on any series ID necessary for carrying out calibration

band_min

(continuous) band of hours to seek day minimum

band_max

same for maximum time

band_suns

same for sunset time

silent

if set to TRUE removes notice of insufficient length for the calibration of single short series

aver_series

set of series IDs (chr) used to calculate the average calibration (if NULL: all stations with valid data are included)

Value

a list of calibration tables, one for each series, plus one average table at the bottom (named "Average")

Note

meas must be organized as 4-field records, all series in the same file, no headers. Column order: station ID, date, time (hour), T, [others fields, if any...] separated by spaces. This field order is mandatory.

Default date format is "ymd" (yyyy/mm/dd). Different combinations can be passed to function with date.format, but separator must be "/"

See also: Eccel, E., 2010: What we can ask to hourly temperature recording. Part I: statistical vs. meteorological meaning of minimum temperature. Italian Journal of Agrometeorology XV(2):41-43.

Author(s)

Emanuele Eccel, Emanuele Cordano emanuele.eccel@iasma.it

References

Eccel, E., 2010: What we can ask to hourly temperature recording. Part II: hourly interpolation of temperatures for climatology and modelling. Italian Journal of Agrometeorology XV(2):45-50 http://www.agrometeorologia.it/documenti/Rivista2010_2/AIAM%202-2010_pag45.pdf,www.agrometeorologia.it

Original algorithm from: Cesaraccio, C., Spano, D., Duce, P., Snyder, R.L., 2001. An improved model for determining degree-day values from daily temperature data. Int. J. Biometeorol. 45: 161-169. http://www.springerlink.com/content/qwctkmlq3tebthek/

See Also

shape_calibration

Examples

data(Trentino_hourly_T)
stations <- c("T0001","T0010","T0129")

calibration_l <- par_calibration(meas = h_d_t[h_d_t$V1 %in% stations,],
                 missing_value_code = -999.9,
					band_min = 4:8, band_max = 13:16,
					band_suns = 16:20, cal_period = NULL)

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(Interpol.T)
Loading required package: date
Loading required package: chron
> png(filename="/home/ddbj/snapshot/RGM3/R_CC/result/Interpol.T/par_calibration.Rd_%03d_medium.png", width=480, height=480)
> ### Name: par_calibration
> ### Title: Calibration of "hour" parameters for temperature interpolation
> ### Aliases: par_calibration
> 
> ### ** Examples
> 
> data(Trentino_hourly_T)
> stations <- c("T0001","T0010","T0129")
> 
> calibration_l <- par_calibration(meas = h_d_t[h_d_t$V1 %in% stations,],
+                  missing_value_code = -999.9,
+ 					band_min = 4:8, band_max = 13:16,
+ 					band_suns = 16:20, cal_period = NULL)
[1] T0001
[1] T0010
[1] T0129
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>