Skip to content

Perform an API call to gather weather data for cities based on a set of random coordinates. Choose best city to vacation based on weather criteria and generate a map with city information

Notifications You must be signed in to change notification settings

Geneille/World_Weather_Analysis

Repository files navigation

World_Weather_Analysis

Overview & Objectives

This project aims to plan a trip for a vacation based on a specific temperature criteria between 75 and 90 degress Fahrenheit. With no specific destination in mind, and hence no lodging location, certain steps were undertaken to provide a complete vacation iternary. To fulfill this goal, the following objectives were completed:

  1. Retrieve weather data by generating a set of random latitudes and longitudes
  2. Create a travel destinations map based on customer input temperature preferences
  3. Create a travel itinerary map

Analysis Overview

Calling on Numpy random function in Jupyter Notebook, a set of 2,000 random latitudes and longitudes was first generated and the nearest city to these geographical location was retrieved. An API call with the OpenWeatherMap was then made to collect the city weather data, including the current weather description (at the time the call made). The information was stored in a DataFrame and exported (WeatherPy_Database.csv) for further analysis. The full code can be found in the Weather_Database.ipynb file.

Using the weather data collected, a set of cities and nearby hotels was selected as potential travel destinations based on preferred input temperature in Jupyter Notebook. These destinations were then illustrated on a map with pop-up markers. (See Vacation_Search.ipynb file)

Finally, the Google Directions API was used to create a travel itinerary that shows the route between four cities chosen from the customer’s possible travel destinations. A marker layer map with a pop-up marker for each city on the itinerary was also created.

Results

Table 1 below provides an illustration of the data collected for a few cities.

TABLE 1

Table 2 below illustrates the filtered cities, a count of 185, with nearby hotels.

TB 2

The map is portrayed in Figure 1 below.

Figure 1

fig 1

Figure 2 below shows the proposed roadtrip for a vactaion in Brazil, visiting major cities on the coast.

Figure 2

fig 2

About

Perform an API call to gather weather data for cities based on a set of random coordinates. Choose best city to vacation based on weather criteria and generate a map with city information

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published