GithubHelp home page GithubHelp logo

mrvillafria / surfs_up Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 280 KB

Using Python, SQLAlchemy, and Flask to analyze and visualize climate data

Jupyter Notebook 100.00%
sql sqlite sqlalchemy python database

surfs_up's Introduction

Surfs Up with Advanced Data Storage and Retrieval

Overview of Project

For this week's project, we will be using SQLite and SQLAlchemy in addition to Python and Pandas in a Jupyter Notebook. SQLite is a serverless database engine that allows us to quickly setup a database engine without a server. SQLite is stored locally which allows quick testing in comparison to setting up a SQL database server. SQLAlchemy is a Python library that we'll use for querying data and can be used to perform the same query across different SQL dialects. Object Relational Mapper, ORM, is a primary feature of SQL Alchemy. ORM makes it possible to query a database using SQL or Python.

Purpose

The purpose of this week's project was to run weather analytics for a potential business opportunity called Surf 'n Shake. The idea of Surf 'n Shake is to serve surfboards and ice cream to locals and tourists in Oahu. In order to build a strong business plan for our investors, one of the main concerns we wanted to look into was how temperature could affect the business. We pulled temperature statistics for the months of June and December so we could analyze weather trends. By looking at a summer month and a winter month, this weather data will help determine if Surf 'n Shake is sustainable year-round.

Results

To get the temperature statistics for June and December, we first had to query to retrieve all of the temperatures from our hawaii.sqlite database for those two months. We then converted the temperatures to a list and then created a Dataframe from the list. From there, the easiest way to get basic statistic details was by using Pandas describe method.

Temperature Statistics for June

June_Temps

Temperature Statistics for December

December_Temps

Analysis of June and December Temperature Statistics

Here are three key differences between June and December:

  • There are more data entries for June (1,700) than there is for December (1,517)
  • The average temperature in for June (74.94 degrees) is ~3.9 degrees higher than December (71.04 degrees)
  • The minimum temperature in June (64 degrees) is 8 degrees higher than December (56 degrees)

Summary

After pulling the statistics for the temperatures for June and December, we can see there is not a significant change in temperature between the two months. Although there are less data entries for December in comparison to June, the average temperature of each month is only a few degrees off from each other.

While the temperature is ideal for shakes and catching waves in June and December, we also ran queries on precipitation. There is a chance there may be less customers if it's raining or snowing outside which would not be ideal for business. As you can see below, the precipitation averages for both months are generally low.

Overall, the differences between the summary statistics for the months of June and December are minimal. Basing it off temperature and precipitation, the weather looks favorable for ice cream and surfing in both months. Additional data for sales of surfboards and shakes during these months would also be helpful for further analysis.

Precipitation Statistics for June

June_Prcp

Precipitation Statistics for December

December_Prcp

surfs_up's People

Contributors

mrvillafria avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.