列举 NOAA 的天气状况吗?
我正在尝试使用 NOAA API 进行当前天气状况观测,但不知道是否有它们可以生成的所有可能天气状况的枚举列表。
举个例子,如果我使用 Yahoo 的 API(使用苹果总部附近的 woeid 作为示例)和 URl:
http://weather.yahooapis.com/forecastrss?w=12797509
它返回带有条件标记的数据,其中包含:
<yweather:condition text="Fair" code="34" temp="87" date="Wed, 13 Oct 2010 1:56 pm PDT" />
从此我还可以使用 雅虎!天气 RSS Feed#codes
但相比之下,如果我使用 NOAA 提要并应用 KNUQ 最近的气象站(作为猜测),使用:
http://www.weather.gov/xml/current_obs/KNUQ.xml
我用一个标签返回数据,该标签仅包含
<weather>Fair</weather>
所以我正在寻找的是查看是否有
I am trying to use the NOAA API for current weather conditions observations and don't know if there is an enumerated list of all the possible weather conditions that they can generate.
As an example if I use Yahoo's API (using a woeid near Apples Headquarters as an example) with the URl:
http://weather.yahooapis.com/forecastrss?w=12797509
It returns data with a condition tag containing:
<yweather:condition text="Fair" code="34" temp="87" date="Wed, 13 Oct 2010 1:56 pm PDT" />
From this I can also programmatically map the code of 34 to "Fair" using the API documentation at Yahoo! Weather RSS Feed#codes
But in comparison if I use the NOAA feed and apply the closest weather station of KNUQ (as a guess) using:
http://www.weather.gov/xml/current_obs/KNUQ.xml
I get back data with a tag that simply contains
<weather>Fair</weather>
So what I am looking for is to see if there is an enumeration of the contents of the <weather> tag. I haven't been able to find it on the NOAA site, but I wouldn't be surprised if I am looking in the wrong location.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
可能的天气“短语”及其相关图标的列表位于此处。
The list of possible weather "phrases" and their associated icons is located here.