View Source NOAA.Observations (NOAA Observations v0.4.43)
Fetches weather observations for a US state/territory code.
Link to this section Summary
Functions
Fetches weather observations for a US state/territory code.
Link to this section Functions
Specs
fetch(NOAA.Observations.State.code()) :: {:ok, [NOAA.Observations.Station.observation()]} | {:error, String.t()}
Fetches weather observations for a US state/territory code.
Returns either tuple {:ok, [observation]} or tuple {:error, text}.
Examples
iex> alias NOAA.Observations
iex> {:ok, observations} = Observations.fetch("vt")
iex> Enum.all?(observations, &is_map/1) and length(observations) > 0
true