23 - use case: phenology data

Located here: https://opendata.dwd.de/climate_environment/CDC/observations_germany/phenology

This example uses data in the subfolder annual/crops/hist

rdwd::updateRdwd()
library(rdwd)
phenocrop_base <- paste0(sub("climate$", "phenology", dwdbase), 
                        "/annual_reporters/crops/historical/")
# pheno_urls <- indexFTP("", base=phenocrop_base, dir="Pheno")
kohl_url <- "PH_Jahresmelder_Landwirtschaft_Kulturpflanze_Weisskohl_1951_1990_hist.txt"# 9 MB
kohl_file <- dataDWD(base=phenocrop_base, url=kohl_url, joinbf=TRUE, read=FALSE) 
kohl <- read.table(kohl_file, sep=";", header=TRUE)
summary(kohl)
##   Stations_id     Referenzjahr  Qualitaetsniveau   Objekt_id      Phase_id    
##  Min.   : 7501   Min.   :1951   Min.   : 1.000   Min.   :244   Min.   :11.00  
##  1st Qu.: 9078   1st Qu.:1968   1st Qu.:10.000   1st Qu.:244   1st Qu.:11.00  
##  Median :10232   Median :1976   Median :10.000   Median :244   Median :24.00  
##  Mean   :10189   Mean   :1975   Mean   : 9.998   Mean   :244   Mean   :17.64  
##  3rd Qu.:11211   3rd Qu.:1983   3rd Qu.:10.000   3rd Qu.:244   3rd Qu.:24.00  
##  Max.   :19914   Max.   :1990   Max.   :10.000   Max.   :244   Max.   :24.00  
##  Eintrittsdatum     Eintrittsdatum_QB     Jultag          eor           
##  Min.   :19510406   Min.   :1.000     Min.   : 29.0   Length:50072      
##  1st Qu.:19681015   1st Qu.:1.000     1st Qu.:146.0   Class :character  
##  Median :19761022   Median :1.000     Median :249.0   Mode  :character  
##  Mean   :19746635   Mean   :1.177     Mean   :214.7                     
##  3rd Qu.:19830919   3rd Qu.:1.000     3rd Qu.:282.0                     
##  Max.   :19901113   Max.   :5.000     Max.   :329.0                     
##     X          
##  Mode:logical  
##  NA's:50072    
##                
##                
##                
##