Skip to content

The project processes stock performance data for a list of companies, displays graphs of their past performance, shows the latest available prices, and provides the most recent news. The information is presented in a GUI, making it easy to compare and analyse the performance of multiple companies at once.

Notifications You must be signed in to change notification settings

wleong1/StockTracker

Repository files navigation

StockTracker

StockTracker is a Python application that help analyse and visualise stock performance data for a list of companies. It provides a user-friendly GUI for comparing stock prices, viewing historical trends, and staying updated with the latest news.

Table of Contents

Project Description

StockTracker is designed to simplify stock analysis and decision-making. It fetches stock data for multiple companies, plots interactive graphs, and offers real-time news updates. Key features include:

  • Graphical representation of historical stock prices.
  • Live stock price tracking and display.
  • Integration with Alpha Vantage, providing the latest available closing price.
  • Integrate with News API for up-to-date news related to selected companies.

Technologies

  • Python 3.10
  • PyQt5
  • Bokeh
  • Matplotlib
  • Numpy
  • Pandas
  • Unittest

Installation

  1. Clone the project repository using Git.
  2. Ensure that your pip package manager is up to date by running the command pip install --upgrade pip.
  3. Install the required modules by executing the command pip install -r ./requirements.txt

Usage

  1. Download the stock data from the following source: https://www.kaggle.com/datasets/camnugent/sandp500.
  2. Extract the downloaded file and navigate to the extracted folder.
  3. Locate the directory named individual_stocks_5yr within the first individual_stocks_5yr directory and copy it.
  4. Paste the individual_stocks_5yr directory into the StockTracker repository.
  5. Within the src directory of the project, create a new Python file named parameter.py.
  6. Inside parameter.py, create two variables: NEWS_API_KEY and ALPHA_VANTAGE_API_KEY.
  7. Assign your News API and Alpha Vantage API keys to the respective variables in parameter.py.
  8. Run the main.py file to start the StockTracker application.

Note:

  • This project relies on external data sources and requires valid API keys to access the necessary information. Make sure to provide your own API keys to ensure proper functionality.
  • The demonstration of the GUI functionality utilises older data. To ensure you have the most recent graph representation, replace the provided data with updated information.

Screenshots

image

The image showcases the GUI, featuring elements such as the company selection dropdown menu, latest closing price, current news, and historical performance.

Tests

StockTracker incorporates various tests to ensure its stability and reliability. To execute these tests, follow these steps:

  1. Go to the tests directory.
  2. Replace the sample_data files with a subset of files you intend to test, maintaining a similar naming convention.
  3. Adjust the test scripts as necessary.

Contributing

Contributions to StockTracker are welcome! If you'd like to contribute, please follow these guidelines:

  1. Fork the project.
  2. Create your feature branch (git checkout -b feature/your-feature-name).
  3. Commit your changes (git commit -m 'Add some feature').
  4. Push to the branch (git push origin feature/your-feature-name).
  5. Open a pull request.

License

This project is licensed under the MIT License.

About

The project processes stock performance data for a list of companies, displays graphs of their past performance, shows the latest available prices, and provides the most recent news. The information is presented in a GUI, making it easy to compare and analyse the performance of multiple companies at once.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published