Code Monkey home page Code Monkey logo

phone_mast_processor's Introduction

Phone Mast Data Processor

Load phone mast data, process and output to the console.

Installation

Install using pip:

$ pip install phone_mast_processor

or

$ pipenv run pip install .

Usage

if using Pipenv first activate the shell with pipenv shell

Usage: phone_mast_processor [OPTIONS] FILE

This application processes phone mast data and outputs it to the console.

The names of sections that can be run independently are:

  • rent - produces a list sorted by Current Rent in ascending order. years -
  • list of mast data where Lease Years = 25 years.
  • total rent - the total
  • rent for all items.
  • tenant - tenant name and a count of masts for each tenant.
  • lease start date - data for rentals with Lease Start Date between 1 June 1999 and 31 Aug 2007.

eg phone_mast_processor -s "total rent" data.csv

Development

Install pipenv and run from the base directory. This application has only been tested with Python 3.8 but will require at lease version 3.6 due to this use of f strings:

pipenv install --dev

Test

pipenv run pytest

Things to improve:

- Comments!
- Use the 'typing' library to support type hints e.g. def greeting(name: str) -> str:
- Convince the Product Owner to allow me to use Pandas!
- If the input file cannot be found or is empty, uses requests to download the file from the URL in the requirements.
- Use OS lib to ensure the file path to data is correct cross platform.

phone_mast_processor's People

Contributors

amurphy89 avatar

Watchers

James Cloos avatar  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.