An interactive portfolio analytics system that evaluates stock investments using historical market data. It enables users to allocate capital across selected stocks and analyze performance, risk, diversification, and technical indicators over a chosen time horizon.
Access the dashboard here:
−> Portfolio Analytics Dashboard
This project focuses on understanding how a portfolio behaves as a whole rather than analyzing stocks individually. It integrates multiple financial concepts such as returns, risk, diversification, and technical indicators into a single analytical workflow.
The system:
- fetches historical stock price data from Yahoo Finance
- compares portfolio performance with the NIFTY 50 benchmark
- computes key financial metrics
- visualizes insights through charts and structured layouts
- Multi-stock portfolio construction with custom capital allocation
- Benchmark comparison against NIFTY 50
- Portfolio return and growth analysis
- Risk evaluation using volatility and drawdown
- Sharpe ratio and alpha computation
- Diversification analysis using correlation
- Contribution analysis for each stock
- Sector allocation and breakdown
- Dividend yield estimation
- Technical indicators (MA20, MA50, RSI) with signal generation
- Interactive charts and tab-based analysis views
- Python
- Pandas
- NumPy
- Plotly
- yfinance
- Select stocks and assign investment amounts
- Choose a time period
- Historical price data is fetched
- Portfolio-level metrics are computed
- Results are visualized through charts, tables, and summary cards
-
Overview / Dashboard
-
Performance Analysis
-
Correlation Analysis
-
Allocation View
-
Contribution Analysis
-
Risk Analysis
-
Technical Analysis
-
Fundamentals View
Portfolio Analytics/
├── app.py
├── requirements.txt
├── data/
│ ├── nse_stocks.csv
│ └── sector_map.csv
├── analytics/
├── signals/
├── visuals/
└── screenshots/
pip install -r requirements.txt
streamlit run app.py- This application analyzes historical market data and does not provide any future predictions or investment recommendations
- Results depend on the selected time period and allocation, so different inputs can lead to significantly different insights
- The analysis reflects past performance, which may not be indicative of future outcomes
- Some metrics may vary slightly over time due to updates in market data
- This tool is intended for learning, exploration, and understanding portfolio behavior
This project is for educational purposes only and does not constitute financial advice.







