link between stocks, indexes, and market sectors • Here’s a visual representation of the S&P 500 index… Index: • An assortment of stocks, organized in sectors Sector: • Each stock has a market sector • Many stocks share same sector Stock: • It’s a stock… • attributes like market sector and industry • wowee… finance! C Index Sector A B ^Stocks^
Sector, as well as links to the top index it is in (Stock-to-top-index). • Index: Has links to top sectors (Index-to-sector), and links to top stocks (Index-to-top-stocks) • Sector: Has links to top stocks in the sector, and indexes with the most weight in that sector. Many-To-Many relationship tables: • Index-to-sector: Table that tracks all sectors within the index and their weight percentages. • Index-to-top-stocks: Table that tracks the top ten stock within the index with weight percentages. • Stock-to-top-index: Table that tracks the indexes with the most weight in the underlying stock
for static sector data (as a cost-saving technique) - `yfinance` and `yahooquery` libraries for batch data collection leveraging API - Indexes - Stocks - Comprehensive Data - Market cap - Historical Data - Sector weights - Top Holdings
and filtering for user needs - Filtering - Use of SQLAlchemy’s `filter` and `filter_by` methods to build query conditions - Filtering by sector - Sorting - Customizable sorting using `asc` and `desc` methods - Sorting using multiple fields such as Ticker, Name, Current Price - Searching - Full-Text searching across all models - Searching and Filtering Specific Models
out frontend consumes with GET requests are organized by stock, index, or sector - These models have GET all endpoints that support filtering, searching, and sorting. - Each model also has a corresponding GET by primary key endpoint - The API also has POST, PUT and DELETE endpoints for creating, updating, and deleting model instances but these are not used by the frontend. - In the backend, the flask route queries the DB with SQLAlchemy, applies any sorts or filters, paginates the result and returns a JSON response
- Worked well as a team - A visually appealing UI - What we learned? - How to construct association tables for many-to-many relationships in our DB - Data Interaction with React - Flask - GCP Deployment - What we could do better? - Searching across all 3 models - Simplifying filtering applications and resets - What puzzles us? - Deploying frontend and backend simultaneously under one GCP project - DB many-to-many relationships - Why the cost of our website on GCP was so high and how we could fix that issue?
and UI - Spotify extension - Cards flip on check - Navigation - What we learned? - Ways to make website more interactive (flipping cards, spotify extension, etc.) - How to make a website visually appealing and intuitive (UI, animations, indicators) - What puzzled us? - Filtering: nothing changes when you click the filtering categories - Top 50 tab - What could be improved? - Implement/improve filtering - Change “Top 50” to “Top 50 Songs” for clarity