| readDWD | R Documentation |
Read climate data that was downloaded with dataDWD().
The data is unzipped and subsequently, the file(s) are read, processed and
returned as a data.frame / terra raster object.
For observational data, new users are advised to set varnames=TRUE
to obtain more informative column names.
readDWD will call internal (but documented) subfunctions depending on the
argument type, see the overview in fileType().
Not all arguments to readDWD are used for all subfunctions, e.g.
fread is used only by readDWD.data, while dividebyten
is used in readDWD.raster and readDWD.asc.
file can be a vector with several filenames. Most other arguments can
also be a vector and will be recycled to the length of file.
readDWD(
file,
type = fileType(file),
varnames = FALSE,
fread = NA,
format = NA,
tz = "GMT",
hr = 0,
dividebyten = TRUE,
var = "",
progbar = !quiet,
quiet = rdwdquiet(),
quietread = quiet,
...
)
file |
Char (vector): name(s) of the file(s) downloaded with
|
type |
Character (vector) determining which subfunction to call.
DEFAULT: |
varnames |
Logical (vector): Expand column names?
Only used in |
fread |
Logical (vector): read fast? Used in |
format, tz |
Format and time zone of time stamps, see |
hr |
Integer code to merge historical and recent file.
Used here, but documented in detail in |
dividebyten |
Logical (vector): Divide the values in raster files by ten?
That way, [1/10 mm] gets transformed to [mm] units.
Used in |
var |
var for |
progbar |
Logical: present a progress bar with estimated remaining time? If missing and length(file)==1, progbar is internally set to FALSE, unless binary files are to be read. DEFAULT: !quiet |
quiet |
Logical: suppress messages? DEFAULT: FALSE through |
quietread |
Logical: suppress message like
"Reading 1 file with readDWD.data() and fread=TRUE ...".
DEFAULT: |
... |
Further arguments passed to the internal |
For observational data, an invisible data.frame of the desired dataset,
or a named list of data.frames if length(file) > 1.
For gridded data, terra raster objects.
Berry Boessenkool, berry-b@gmx.de, Jul-Oct 2016, Winter 2018/19
dataDWD(), readVars(), readMeta(), selectDWD(), fileType()
https://bookdown.org/brry/rdwd
# see dataDWD and readDWD.* subfunctions
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.