readRadarFile: read binary radolan radar file

Description Usage Arguments Value Author(s) See Also Examples

View source: R/readRadarFile.R

Description

Read a single binary DWD Radolan file. To be used in rdwd.
If any files ar not read correctly, please let me know. So far, tests have only been conducted for some files. Optimally, check the Kompositformatbeschreibung at https://www.dwd.de/DE/leistungen/radolan/radolan.html and let me know what needs to be changed. The meta-info is extracted with readHeader (not exported, but documented)
Binary bits are converted to decimal numbers with Fortran routines, see https://github.com/brry/dwdradar/tree/master/src. They are called via bin2num (not exported, but documented).

Usage

1
readRadarFile(binfile, na = NA, clutter = NA)

Arguments

binfile

Name of a single binary file

na

Value to be set for missing data (bit 14). DEFAULT: NA

clutter

Value to be set for clutter data (bit 16). DEFAULT: NA

Value

Invisible list with dat (matrix) and meta (list with elements from header, see Kompositformatbeschreibung)

Author(s)

Maintained by Berry Boessenkool, berry-b@gmx.de, May + Oct 2019.
Original codebase by Henning Rust & Christoph Ritschel at FU Berlin

See Also

real-world usage in rdwd: https://bookdown.org/brry/rdwd/raster-data.html

Examples

1
2
3
4
5
6
7
8
9
f <- system.file("extdata/raa01_sf_2019-10-14_1950", package="dwdradar")
out <- readRadarFile(f)
out$meta

if(requireNamespace("raster", quietly=TRUE))
  raster::plot(raster::raster(out$dat))

# for more files, see the tests.
# for real-world usage, readDWD.binary / readDWD.radar in the rdwd package

dwdradar documentation built on Aug. 10, 2021, 9:07 a.m.