Learn R Programming

Interpol.T (version 2.1.1)

plot_meas_sim: Plots hourly curves

Description

Plots curves for comparison between measures and simulations (hourly interpolations)

Usage

plot_meas_sim(meas, sim, series = NULL, chart.start, chart.end, date.format = "ymd", missing_code = NA, wait = 1, plot.leg = TRUE, leg.pos = "bottomright")

Arguments

meas
measured hourly values file (table), where the first column is the series' ID
sim
simulated hourly list (output of Th_int_series)
series
names of the seris to plot. If NULL, plots all the series
chart.start
start date for the plotting. Format example: "1Jan2000"
chart.end
end date for the plotting. Format example: "1Jan2000"
date.format
input date format for measurements (formats for function chron). Default is "ymd"
missing_code
code (either real or character) for missing values in measurements. Default is NA
wait
lag time (seconds) between plot appearance on the screen (default is 1 second)
plot.leg
logical: if TRUE (default) legends are plotted
leg.pos
position of legends (only if plot.leg = TRUE). Default is "bottomright". Values for par can be passed to function

Value

A plot with two curves: measured values and hourly interpolations

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

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. http://www.agrometeorologia.it/documenti/Rivista2010_2/AIAM%202-2010_pag41.pdf

Examples

Run this code
data(Trentino_hourly_T)
stations <- c("T0001","T0010","T0129")
plot_meas_sim(meas = h_d_t, sim = Th_int_list, series=stations,
              missing_code = -999.9, chart.start = "1Feb2004",
             chart.end = "29Feb2004", leg.pos = "top")

Run the code above in your browser using DataLab