This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
Project Structure
The project is organized into logical folders to separate functionality and keep the codebase easy to navigate.
stock_crypto/
│
├── core/
│ ├── indicators.py # calculates all the indicators (EMA,SMA etc)
│ ├── market_screener.py # screens the market, creates data for heatmaps and networking graphs(correlations)
│ ├── network_graphing.py # plots the correlations in plotly and creates clusters
│ ├── portfolio.py # generates portfolio for user-input-data
│ ├── verdict.py # Is the main structure of the verdict system and adds the indicator verdicts up
│ └── prediction.py # uses easy deterministic predicting method to predict a certain timeframe
|
├── data/
│ └── fetch_data.py # fetches data from yahoo finance
│
├── GUI/
│ ├── colour_coding.py # colour coding for the heatmaps based on data
│ └── user_interface.py # creates the user interface and gets user input
│
├── indicators_verdict/
│ ├── bollinger_verdict.py # creates a verdict according to the bollinger values
│ ├── ma_verdict.py # creates a verdict based on ema and sma indicators
│ ├── macd_verdict.py # creates a verdict based on the macd movements, crossovers etc
│ └── rsi_verdict.py # uses rsi indicators to create a verdict
│
└── main.py # Streamlit UI logic and app entry point
notebooks/
├── indicators_guide.ipynb # explains indicators and their equations further
├── network_guide.ipynb # explains the correlation networks further
├── prediction_methods.ipynb # explains the prediction further
🔷 /core
Contains the main business logic of the application.
indicators.py
Calculates technical indicators such as SMA, EMA, ATR, RSI, MACD, etc. Uses the Pandas DataFrame.rolling() function to compute moving window values. Reference: https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.rolling.html
market_screener.py
Screens the entire S&P 500 market Prepares data used for: Heatmaps Correlation matrices Network graph analysis network_graphing.py Creates Plotly network graphs based on correlation data. Reference: https://plotly.com/python/network-graphs/
portfolio.py
Provides a lightweight portfolio tracking feature: Accepts user-provided positions Calculates performance and value changes
prediction.py
Implements a deterministic prediction method to estimate future prices over a defined time window.
verdict.py
It contains the master class of verdicts, it uses the indicators_verdict folder to get verdicts, adds them up and creates a final verdict
🔷 /data
fetch_data.py
Handles all data acquisition from external sources such as Yahoo Finance. Commonly uses the yfinance library. Reference: https://pypi.org/project/yfinance/
🔷 /GUI
colour_coding.py
Generates color schemes and mapping rules for heatmaps and other visual elements based on indicator results.
user_interface.py
Defines the Streamlit user interface, including: Layout Input elements Page navigation and structure Streamlit documentation: https://docs.streamlit.io/
🔷indicators_verdict -> applies to ALL of the files
Creates a numerical verdict for their respective indicator and returns it to verdict.py
🔷 main.py
Entry point of the entire application. Initializes the Streamlit environment, loads modules, and ties user interactions to backend computations.
🔷 /data_saved
This folder contains static data files used for testing, historical analysis, or caching purposes.
heatmap_parquet– historical stock price data for S&P 500correlations.json– networking plotly graphs as json
🔷 /notebooks
This folder contains code snippets of complicated modules, trying to explain everything by viusalizing code through jupyter notebooks
Notes
- These files are read-only and should not be modified directly by users.
- Any new datasets should be placed here for consistency.