# DWD weather stations

#### 2018-03-29

rdwd main vignette

The `rdwd` package provides a collection of all the metafiles on the DWD data server. It is presented as an interactive map below.

When a point is clicked, an infobox should appear. The first line can be copypasted into R to obtain more information on the available files. The map is created with the following code:

    library(rdwd)  ;  data(geoIndex)  ;  library(leaflet)
    leaflet(geoIndex) %>% addTiles() %>%
            addCircles(~lon, ~lat, radius=900, stroke=F, color=~col)%>%
            addCircleMarkers(~lon, ~lat, popup=~display, stroke=F, color=~col)

Open this vignette locally for faster map reaction times than on the CRAN html view:

    vignette("mapDWD")

The blue dots mark stations for which recent files are available (with >=1 file in ‘recent’ folder or ‘BIS_DATUM’ later than one year ago). The red dots mark all stations with only historical datasets.

To see only the stations with recent data, use the following code:

    library(rdwd)  ;  data(geoIndex)  ;  library(leaflet)
    leaflet(data=geoIndex[geoIndex$recentfile,]) %>% addTiles() %>%
            addCircleMarkers(~lon, ~lat, popup=~display, stroke=F)

To request the nonpublic datasets counted in the infobox, please contact klima.vertrieb@dwd.de. (The DWD cannot publish all datasets because of copyright restrictions).

Note: `geoIndex` is created in the last section of rdwd-package.R.