"What's the weather like as we approach the equator?"


I created a Python script to visualize the weather of 500+ cities across the world of varying distance from the equator. I utilized a simple Python library and the OpenWeatherMap API to create a representative model of weather across world cities. I created a series of scatter plots to show the following relationships: Temperature (F) vs. Latitude, Humidity (%) vs. Latitude, Cloudiness (%) vs. Latitude, and Wind Speed (mph) vs. Latitude.

There was a strong correlation between maximum temperature and latitude. Low latitude regions had higher maximum temperature compared with high latitude regions (Fig. 1). There were no correlations between latitude and humidity, cloudiness, and wind speed. These variables might be related with weather. Weather frequently changes anywhere in the world, either high or low latitude; therefore, there might not be a relationship between latitude and the other variables. I created a dataset for the northern and the southern hemispheres to examine the relationship between the maximum temperature and latitude. There was a negative relationship between the maximum temperature and latitude in the northern hemisphere, but there was a positive relationship between the maximum temperature and latitude in the sourthern hemisphere (Fig. 2, 3).


Temp_Latitude_Graph
Latitude vs Temperature
Latitude vs Humidity


"My ideal weather condition & Nearby hotel information"


I used gmaps to create a heat map that weighed the humidity for every city in the world. To create my favorite weather condition, I set up the dataframe with the cities having maximum temperature with >65F, <85F, humidity with <55%, and wind speed with <10mph. Using Google Places API, I looped through all cities in the dataset to find a hotel that was located within 5 km of each city coordinate. I added a marker on the map to show the hotel, city, and country information.

humidity_map
hotel_map

** Data Files and More Information Available @ GitHub:Climate-Map-Project **


Copyright © 2020 Yukie Kajita