Unlock Weather Insights: How You Can Use Power BI with OpenWeatherMap — Part 2
In the previous article of this series, we created an OpenWeatherMap account, copied and then used the default API key to retrieve the current weather for the location you were interested in. In this article, we will retrieve the weather forecast information using the “5 Day / 3 Hour Forecast” API call, as this suited my requirements. After we have loaded and cleaned the data, we will start building our dashboard.
Loading Weather Forecast Information into Power BI
Open the Power Query window by clicking “Transform Data” in Power BI Desktop. Now follow the following steps:
- Go to the home tab and select “New Source”. This will open a short menu of potential data sources.
- Select the “Web” option. This opens the From Web box so you can enter the URL for data retrieval.
Enter the following URL.
http://api.openweathermap.org/data/2.5/forecast?
lat=<Your Town latitude>&
lon=<Your town longitude>&
APPID=<Paste in your API Key using CTRL+V or Command+V &
units=Metric
(If you wish to use Imperial measurements change Metric to Imperial)
Replace <Your Town Latitude>, <Your Town Longitude>, and <Paste in your API Key using CTRL+V or…