Roberto Zorer 1*, Luca Delucchi 1, Duccio Rocchini 1, Amedeo Fadini 1, Markus Neteler 1
1 GIS and Remote Sensing Unit
Biodiversity and Molecular Ecology Department - DBEM Fondazione Edmund Mach - www.fmach.it
Via E. Mach 1, 38010 San Michele all'Adige (TN) - Italy T.+39 0461 615570 - F.+39 0461 650956
Abstract
Weather forecasting is a very important issue not only for agriculture but also for tourism, and particularly for the management of extreme events. Web-services and apps for mobile devices are becoming increasingly popular, providing weather forecast related to the user location or to points of interest selected interactively on the map or from destinations lists. There are both free and paid services available, and some of them follow open-data policy.
Services that provide the ability to perform requests via API are of particular interest, since they allow machine-to-machine calls, by automating the population of local databases, and, finally, developing and implementing new services.
In the present work, we developed and implemented Python-scripts and libraries to obtain a fully automated data flow from the daily download of data from two weather forecast web-services, to the population of a PostgreSQL geo-database. The accuracy assessment of the forecasting time-series of mean daily air temperature is presented and discussed. Keywords
Weather, web-service, yr.no, meteoblue.com, uncertainty Parole chiave
Meteo, servizio web, yr.no, meteoblue.com, incertezza Introduction
The offer of online weather services is continuously growing on the web and, at the same time, the number of people depending on weather forecast to plan their schedules is increasing. On the contrary, accurate monitoring of current conditions by means of weather stations and the implementations of forecast models is demanding and expensive.
Moreover, some weather forecast services offer data by means of Application Programming Interface (API) providing access to weather related data (“API Data”) with direct http-queries to their servers. The queries can be executed instantaneously or scheduled through machine-to- machine automated requests, providing latest up-to-date data as eXtensible Markup Language (XML) text. These can be automatically processed with scripts (i.e. Python programming language) and the data stored back into local databases for any use.
In the present work we assessed a free online weather service from both the Norwegian Meteorological Institute (http://met.no) and the Norwegian Broadcasting Corporation (NRK - http://yr.no), and the commercial online weather forecast service provided by Metoblue/Meteoarena (http:///www.meteoblue.com) with respect to their degree of certainty, using ground–truth weather data.
Materials and Methods
yr.no free weather data service
Yr.no offers free weather data in XML format for 7 million places around the world or for user-specified coordinates. The modules implements a full forecast with several parameters for a nine-day period. The mandatory input parameters of the http-request are latitude and longitude (decimal degrees), optional is the elevation (whole meters above sea level).
The XML-output include air temperature and humidity, wind speed, wind direction, pressure, precipitation, cloudiness, fog, low clouds, medium clouds, high clouds. We monitored 20 of 64 sites corresponding to the location of the weather stations used for validation.
meteoarena.com/meteoblue.com
The meteoblue API is a weather interface designed for professional clients. With the API, clients can link to meteoblue live forecasts with direct http-queries to meteoblue servers. The queries are executed instantaneously and always provide latest up-to-date data. These can be automatically downloaded to local system through a web-service. The PointAPI-service requires an user API-key, the localisation by geographic latitude /longitude coordinates (decimal degrees) or location ID, and the elevation of the site (meters above see level). The http-request returns data as text (XML with CSV) or images (meteogram). We obtained access to the meteoblue services through the Italian distributor Meteoarena (http://www.meteoarena.com) for 40 sites, of which 20 correspond to weather stations.
XML processing
The XML-outputs of both the online weather forecast services have been processed using Python programming language scripts and libraries (python-yr), to allow the automated extraction of the meteorological features and to upload the values into a local PostgreSQL geo-database (ver. 9.1 - PostgreSQL Global Development Group). meteo.fmach.it
Ground–truth weather data used for the assessment of certainty of the two online forecast services were acquired every 15 minutes by 64 automatic weather stations of the CTT – SIG network (Fondazione Edmund Mach – FEM San Michele all’Adige, Trento, Italy). We firstly focused on the time-series of daily average air temperature.
Results and Discussion
The comparison occurred on a 117-day period from December 19, 2014 to April 14, 2015, in which all three datasets were available and complete.
The measured air mean temperatures from 20 meteorological stations varied between -6.0 and 17.1 °C with an average of 4.2° C and a standard deviation of 4.2 °C. Table 1 reports the main parameters to measure forecast accuracy (Sum of Forecast Errors – SFE, Mean Absolute Deviation – MAD, Mean Absolute Percentage Error – MAPE, Mean Squared Error – MSE, Tracking Signal (TS), slope, intercept Pearson and determination coefficient of the linear regression are reported (Mahadevan, 2009). Conclusions
Most of the indicators for accuracy show a better performance of the meteoblue.com service, but both datasets are close to the 1:1 ratio and with a limited spread of the residuals.
The two tested weather forecast services seem to be promising and represent a viable solution to complement physical networks of weather stations.
Tab.1 – Summary of the main parameters used to assess forecast accuracy.
Tab.1 – Sommario dei parametri principali utilizzati per la determinazione dell’accuratezza della previsione.
Fig.1- Linear regression (medium-dashed line) between predicted and observed values of daily mean air temperature. A. Data from meteoblue.com service. B. Data from yr.no free forecast service. The bold-solid line represents the 1:1 correlation.
Fig.1 – Regressione lineare (linea tratteggiata) tra valori predetti e attesi di temperatura media dell’aria. A. Dati del servizio PointAPI di meteoblue.com. B. Dati del servizio libero di previsione yr.no. La linea continua in grassetto indica la correlazione 1:1.
Acknowledgments
We greatly thank the colleagues of FEM CTT-SIG for providing (http://meteo.fmach.it) weather station data used for validation.
This activity was co-funded by the EU-WineNet project (https://sites.google.com/site/progettowinenet/).
References
Mahadevan B., 2009. Operations Management; Theory and Practice. 2nd Ed., Pearson Education, New Delhi, 672 pp.