Plot sub-daily data points divided by month.
plot_subdaily(
subdailydata,
year = NA,
outfile,
fixed = TRUE,
units = NA,
time_offset = 0,
...
)A character string giving the path of the input file, or a 7-column matrix with following columns: variable code, year, month, day, hour, minute, value.
Integer vector giving the year(s) to plot. If not specified (NA), all available years will be plotted. One pdf per year will be created.
Character string giving the path of the output pdf file. If
year has more than one element or is NA, then this is a root to the
filenames to which the year will be added ('root.year.pdf').
If TRUE (default), use the same y axis for all months. If FALSE, the axis limits are set based on the data range of each month.
Character string giving the units (will be printed in the y-axis).
If subdailydata is a path to a file, then the units are read from the
SEF header.
Numeric vector of offsets in hours to be applied to the observation times. Recycled if only one value is given. The default is no offset, i.e. UTC times for SEF input.
Graphical parameters passed to the function plot,
such as cex, lwd, pch, col, etc.
(see par).
Stefan Hunziker, Yuri Brugnara
Creates one pdf for each year plotted.
The input file must follow the C3S Station Exchange Format (SEF).
The parameter time_offset can be used to plot observations in local time
when reading the data in SEF.
Hunziker et al., 2017: Identifying, attributing, and overcoming common data quality issues of manned station observations. Int. J. Climatol, 37: 4131-4145.
Hunziker et al., 2018: Effects of undetected data quality issues on climatological analyses. Clim. Past, 14: 1-20.
plot_subdaily(Bern$p, year = 1803:1804, outfile = paste0(tempdir(),"/test"))
Run the code above in your browser using DataLab