Giter Site home page Giter Site logo

plunge's Introduction

plunge

Plunge into the word of securities!

Requirements

  • Ruby 2.5.1p57
  • Bundler 1.16.1

Install required dependencies from the Gemfile:

bundle install

Usage

To query the Quandl WIKIP Stock Price API you need a token. To obtain a token you just need to create a free account with Quandl.

To use the script, move to the lib/ directory (until I will have time to create a proper gem) and run the pc (plunge command line) ruby file.

Supported operations

Get the monthly average of a security with the -a option:

ruby pc.rb -t <your_token> -a GOOGL

Get the days in which the data set would provide the highest amount of profit for each security if purchased at the day’s low and sold at the day’s high:

ruby pc.rb -t <your_token> -m GOOGL

Get the days where the volume was more than 10% higher than the security’s average volume:

ruby pc.rb -t <your_token> -bd GOOGL

Or find that out all together:

ruby pc.rb -t <your_token> -a -m -bd GOOGL

Development

Before running the test, place your token in a file named token in the main project directory. Run the tests with the command rspec or bundle exec rspec if you didn't install rspec globally in your system.

Future work

  • Query API to return directly all the data we need when possible, rather than queriying multiple times for different days.
  • Fix cache

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.