Snow-and-Weather-Data-in-France: Get measured wether and snow data for French Alps and...

Description Usage Arguments Author(s) References See Also Examples

Description

Get measured wether and snow data for French Alps and Pyrennes

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
  getMeteoDataFrance(url = "https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Nivo/nivo.XDATE.csv",
  dest = system.file("dest", package = "MeteoDataFrance"),
  method = c("wget", "curl"), dates = as.character(Sys.Date() - 10:1, format
  = "%Y%m%d"), times = c(0, 3, 6, 9, 12, 15, 18, 21),
  date_indicator = "XDATE", time_indicator = "XTIME",
  force.download = FALSE, smet.output = TRUE, url_stationcoord = c(csv =
  "https://donneespubliques.meteofrance.fr/\ndonnees_libres/Txt/Nivo/postesNivo.csv",
  json =
  "https://donneespubliques.meteofrance.fr/\ndonnees_libres/Txt/Nivo/postesNivo.json"),
  spoutput = FALSE,
  metaparam = read.table(system.file("metadata/paramnames.csv", package =
  "MeteoDataFrance"), sep = ",", header = TRUE, stringsAsFactors = FALSE), ...)

Arguments

url

URL with data. See "https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Nivo/nivo.20150810.csv" or https://donneespubliques.meteofrance.fr/?fond=produit&id_produit=94&id_rubrique=32

dest

destination directory where the downladed csv file is saved

method

method applied in download.file

dates

string containg dates on which date are requested to be downloaded. Actually the date format is %Y%m%d, es. 20150810 for 10 August 2015.

times

vector containg the hours at which date are requested to be downloaded (in case of subdaily data)

date_indicator

string contained in url which is replaced by dates

time_indicator

string contained in url which is replaced by times

force.download

logical value. If TRUE files are forced to be downloaded and then overwritten, if it is FALSE (default) and the files already exist in destdir directory are not downloaded.

smet.output

logical value. Default is FALSE. If it TRUE, output field names are translated in accordance with SMET format files. (http://models.slf.ch/docserver/meteoio/html/smetio.html)

url_stationcoord

string containings the csv and json files with stataion geographic metadata.

spoutput

logical value. Default is FALSE. If it TRUE, spatial information (station coordinates,etc.) are added through url_stationcoord.

metaparam

data.frame table containg all metainformation for each variable: name, ID, type, SMET name, measurement unit,unit multiplier and description.

...

further arguments

Author(s)

Emanuele Cordano

References

https://donneespubliques.meteofrance.fr/?fond=rubrique,https://donneespubliques.meteofrance.fr/?fond=produit&id_produit=94&id_rubrique=32

See Also

download.file ,DownloadFiles

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
library(stringr)


url <-  "https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Nivo/nivo.XDATE.csv"

data <- getMeteoDataFrance(url=url,spoutput=TRUE)

head(data[data$numer_sta=="07729",])

 ## SYNOP DATE
url_synop <- "https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Synop/synop.XDATEXTIME.csv"

url_stationcoord_synop <- c(
		csv="https://donneespubliques.meteofrance.fr/
donnees_libres/Txt/Synop/postesSynop.csv",
		json="https://donneespubliques.meteofrance.fr/
donnees_libres/Txt/Synop/postesSynop.json"
)

data_synop <- getMeteoDataFrance(url=url_synop,
	url_stationcoord=url_stationcoord_synop,
 spoutput=TRUE)

##https://donneespubliques.meteofrance.fr/donnees_libres/Txt/Synop/postesSynop.json

ecor/MeteoDataFrance documentation built on May 15, 2019, 8:01 p.m.