Skip to content

Analyzed the weather of 500+ cities using the OpenWeatherMap API. Displayed results using pandas, linear regressions via matplotlib, and a heatmap using Google Places API.

Notifications You must be signed in to change notification settings

laurenemilyto/gmap-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Google Maps API

map

Description

Used a python script and matplotlib to:

  1. Analyze the weather of 500+ cities across the world of varying distance from the equator using OpenWeatherMap API. Analyzed data to showcase relationships between temperature, humidity, cloudiness, windspeed and latitude across cities. Ran a linear regression to see if there was correlation between these factors in Northern or Southern Hemispheres.
  2. Analyze lodging from Google Places API to find an ideal vacation city (located within 5000 meters of coordinates). Plotted hotels on top of a heatmap with each pin containing the Hotel Name, City, and Country.

Instructions

Please use below links to view:

  1. WeatherPy notebook: Link
  2. VacationPy notebook: Link

Insights from WeatherPy Analysis:

  • Temperature and Latitude have a positive relationship in the Southern Hemisphere. As a city's latitude increases, its temperature does as well. In the Northern Hemisphere, Temperature and Latutitude have a negative relationship. As a city's latitude decreases, temperature also decreases. Therefore, Latitude and Temperature are strongly correlated.
  • Looking at the relationship between Temperature and Latitude, the Northern Hemisphere has a slightly lower r-squared value (0.626) than the Southern Hemisphere (0.783). This means there is a higher percentage of variance across Northern cities and their temperatures, perhaps due to the fact 3x more cities are located North of the Equator in the dataset.
  • Temperature, Humidity, Cloudiness and Wind Speed are not strongly correlated with Latitude. Looking at each linear regression, one can see the large number of outliers, and that the line of best fit shows a weak relationship.

About

Analyzed the weather of 500+ cities using the OpenWeatherMap API. Displayed results using pandas, linear regressions via matplotlib, and a heatmap using Google Places API.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published