A powerful and interactive sales analytics dashboard built with Streamlit, offering comprehensive insights into superstore sales data.
- Real-time KPI Metrics: Track sales, profit, and order volumes with year-over-year changes
- Interactive Filtering: Filter data by year for targeted analysis
- Rich Visualizations:
- Category Performance Scatter Plot
- Order Distribution Sunburst Chart
- Monthly Sales Trends Line Chart
- Top Products Analysis
- Shipping Performance Gauge
- Category Sales Trends
- Streamlit: Core framework for building the web application
- Pandas: Data manipulation and analysis
- Plotly: Interactive plotting (scatter plots, sunburst charts, gauges)
- Altair: Declarative statistical visualizations
- NumPy: Numerical computations
- Millify: Number formatting
- Python 3.12+
- Required Python packages:
streamlit pandas numpy plotly altair millify
- Excel dataset:
superstore_enriched.xlsx
- Clone the repository
- Install dependencies:
pip install -r requirements.txt
- Run the dashboard:
streamlit run app.py
- Sales total with YoY change
- Profit total with YoY change
- Order count with YoY change
- Scatter plot showing Sales vs Profit by Category
- Sunburst chart displaying order distribution by Region and Segment
- Interactive line chart showing monthly sales trends by year
- Top 10 selling products
- Top 10 most profitable products
- Gauge chart showing average shipping days
- Stacked bar chart displaying sales trends by product category
The dashboard uses a custom color palette:
CUSTOM_COLORS = {
'Furniture': '#005C53',
'Office Supplies': '#9FC131',
'Technology': '#042940'
}
- Data loading is cached using
@st.cache_data
- Efficient data filtering and aggregation
- Responsive layout using Streamlit's column system
- Constants: Configuration and color definitions
- Data Loading: Cached data loading and preprocessing
- UI Styling: Custom styling for metrics and layout
- Dashboard Components: Modular functions for each visualization
- Main Function: Orchestrates the dashboard assembly
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.