Skip to contents

Fetch stations metadata based on country, parameter id, ... using Frost v1. To handle such a large request output, a pagination protocol is used. The function gets station names, locations and alternate ids.

Usage

get_metadata_pagination(
  country = "norge",
  paramid = 211,
  timestamp = "1000-01-01T00:00:00Z/2100-01-01T00:00:00Z",
  hdrshow =
    "{\"id\":{},\"extra\":{\"station\":{\"location\":[],\"alternateids\":[]}}}",
  path = sprintf("output/stn_%s_%i", country, paramid)
)

Arguments

country

A country name as string and defined by met.no

paramid

A parameter number as integer and defined by met.no

timestamp

A time range as timestamp or string "latest"

hdrshow

A JSON string containing metadata structure to extract

path

A path where will be saved the metadata as SpatVector `.gpkg`

Value

Stations metadata

Examples

#get_metadata_pagination(country = "norge", paramid = 211)