# Give weather station name (must be existing in metaIndex):
findID("Potsdam", exactmatch=FALSE)
selectDWD("Potsdam", res="daily", var="kl", per="historical")
# all files for all stations matching "Koeln":
selectDWD("Koeln", exactmatch=FALSE)
findID("Koeln", FALSE)
# or directly give station ID:
selectDWD(id="00386", res="daily", var="kl", per="historical")
selectDWD(id=386, res="daily", var="kl", per="historical")
# period abbreviatable:
selectDWD(id="00386", res="daily", var="kl", per="h")
selectDWD(id="00386", res="daily", var="kl", per="h", meta=TRUE)
# vectorizable:
selectDWD(id="01050", res="daily", var="kl", per=c("r","h"))
selectDWD(id="01050", res="daily", var="kl", per="rh", outvec=TRUE)
selectDWD(id="01050", res=c("daily","monthly"), var="kl", per="r")
# vectorization gives not the outer product, but elementwise comparison:
selectDWD(id="01050", res=c("daily","monthly"), var="kl", per="hr")
# all zip files in all paths matching id:
selectDWD(id=c(1050, 386))
# all zip files in a given path (if ID is empty):
head( selectDWD(id="", res="daily", var="kl", per="recent") )
# See if warnings come as expected and are informative:
selectDWD()
selectDWD(7777)
selectDWD(id=7777)
selectDWD(id="", res="dummy", var="dummy")
selectDWD(res="dummy")
selectDWD(res="daily", per="r")
selectDWD(res="daily", var="kl")
selectDWD(id="01050", res=c("daily","monthly"), var="kl") # needs 'per'
selectDWD(id="00386", meta=TRUE)
selectDWD("Potsdam", res="daily", var="solar")
# should be an error:
berryFunctions::is.error( selectDWD(id="Potsdam", res="daily", var="solar"), TRUE)
berryFunctions::is.error( selectDWD(id="", current=TRUE) , tell=TRUE, force=TRUE)
Run the code above in your browser using DataLab