Code Monkey home page Code Monkey logo

scif3000-dbproject's Introduction

Scif project for Tourism Australia

Description

This project automates processing and visualization of data directly from a database. It can adjust outputs subject to user inputs, and provides data on trend and forecast.

Table of Contents

Installation

This project requires some python libraries for its functionality. Please make sure you have python3 properly installed on your machine, as well as the following libraries.

  • postgresql
  • sqlalchemy
  • pandas
  • matplotlib
  • reportlab
  • statsmodels
  • datetime (part of standard library, but please double check)

Example installation commands

pip install postgresql
pip install sqlalchemy
pip install pandas
pip install matplotlib
pip install reportlab
pip install statsmodels
pip install datetime

common troubleshoots: If pip did not work for you, replace pip with pip3.
If your terminal shows that pip did not exist, do the following:
for macOS:
type in terminal: sudo easy_install pip
for ubuntu/linux:
type in terminal: apt-get install python3-pip
for windows:
Instead of pip install [package], try using python -m pip install [package]

Usage

Run qry_generation.py, the terminal will prompt you to enter IATA codes of desired airports of origin. The inputs are case insensitive. To finish entering origins, press 'q' and press enter. Please note that there needs to be at least 1 airports of origin.
Then the terminal will prompt you to type which continents airports of origin originated from. Currently this only intakes one of the following: asia, northamerica, europe, oceania.

After pressing enter, the inputs will prompt user to type in IATA codes of desired airports of destination and press Enter. To stop typing, press 'q' and press enter. By default, the airports of destination is set to international airports all over Australia. Also note that the the airports of destination should be within Australia.

Finally, the program will run and produce the output pdf in output.pdf in the directory.

note: There will be graphs popping out after run. It is expected behavior, simply close all the graphs. The resulting pdf is named output.pdf and everytime this script is run, it will be automatically updated.

Notes of usage:

This code is based on pgSQL database provided by cirium. It may not work on databases with different column and table names.
To adjust the dtaabase this code is reading from, change the database URI by adjusting the db_uri variable.

Contributing

Avinash Dansinghani
Coco Wu
Lucy Lu [email protected] (enquiries about usage and problems)

scif3000-dbproject's People

Contributors

cocochaoku avatar luscarl 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.