# datawithrs/powerbi-sales-analytics architecture

> Architecture diagram of the GitHub repository datawithrs/powerbi-sales-analytics, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/datawithrs/powerbi-sales-analytics
- Repository: https://github.com/datawithrs/powerbi-sales-analytics

## Overview

This repository is a Power BI e-commerce analytics product: CSV datasets feed a modeled report, which presents seven audience-focused dashboard pages. The README documents both a product-level star-schema shape and an order-level flat-table alternative, plus 22 DAX measures and the report’s analysis areas. Relationships below follow only those documented descriptions; the PBIX internals were not available as source excerpts, so detailed visual-to-measure or model-to-page connections are not asserted.

Main entry points: [`Ecommerce-Sales-Analytics.pbix`](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix) (DAX measures), [`order_items.csv`](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/order_items.csv) (Order items), [`customer_master.csv`](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/customer_master.csv) (Customer master), [`product_catalog.csv`](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/product_catalog.csv) (Product catalog)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_data["Data files"]
  node_items["Order items<br/>[order_items.csv]"]
  node_customers["Customer master"]
  node_products["Product catalog"]
  node_flat["Flat order data"]
  node_statistics["Dataset statistics"]
end

subgraph group_model["Data model"]
  node_star["Star schema"]
  node_flatmodel["Flat-table model"]
end

subgraph group_analysis["Analytics"]
  node_measures["DAX measures"]
end

subgraph group_report["Report pages"]
  node_overview["Executive overview"]
  node_customerinsights["Customer insights"]
  node_productperformance["Product performance"]
  node_profitreturns["Profitability and returns"]
  node_delivery["Delivery and logistics"]
  node_marketing["Marketing and campaigns"]
  node_cover["Overview cover"]
end

node_analyst(("Analyst"))

node_items -->|"models as fact"| node_star
node_customers -->|"joins dimension"| node_star
node_products -->|"joins dimension"| node_star
node_flat -->|"models as flat table"| node_flatmodel
node_star -->|"supports measures"| node_measures
node_flatmodel -->|"supports measures"| node_measures
node_analyst -->|"views report"| node_overview
node_measures -->|"reports metrics"| node_overview
node_measures -->|"reports metrics"| node_customerinsights
node_measures -->|"reports metrics"| node_productperformance
node_measures -->|"reports metrics"| node_profitreturns
node_measures -->|"reports metrics"| node_delivery
node_measures -->|"reports metrics"| node_marketing
node_analyst -->|"views report"| node_customerinsights
node_analyst -->|"views report"| node_productperformance
node_analyst -->|"views report"| node_profitreturns
node_analyst -->|"views report"| node_delivery
node_analyst -->|"views report"| node_marketing
node_analyst -->|"views report"| node_cover

click node_items "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/order_items.csv"
click node_customers "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/customer_master.csv"
click node_products "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/product_catalog.csv"
click node_flat "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/ecommerce_sales_customer_analytics_150k.csv"
click node_statistics "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/dataset_statistics.csv"
click node_star "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_flatmodel "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_measures "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_overview "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_customerinsights "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_productperformance "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_profitreturns "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_delivery "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_marketing "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"
click node_cover "https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_items,node_customers,node_products,node_flat,node_statistics toneBlue
class node_star,node_flatmodel toneAmber
class node_measures toneMint
class node_overview,node_customerinsights,node_productperformance,node_profitreturns,node_delivery,node_marketing,node_cover toneRose
class node_analyst toneIndigo
```

## Components

### Data files

- [Order items](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/order_items.csv): `order_items.csv`
- [Customer master](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/customer_master.csv): `customer_master.csv`
- [Product catalog](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/product_catalog.csv): `product_catalog.csv`
- [Flat order data](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/ecommerce_sales_customer_analytics_150k.csv): `ecommerce_sales_customer_analytics_150k.csv`
- [Dataset statistics](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/dataset_statistics.csv): `dataset_statistics.csv`

### Data model

- [Star schema](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Flat-table model](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`

### Analytics

- [DAX measures](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`

### Report pages

- [Executive overview](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Customer insights](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Product performance](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Profitability and returns](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Delivery and logistics](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Marketing and campaigns](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`
- [Overview cover](https://github.com/datawithrs/powerbi-sales-analytics/blob/main/Ecommerce-Sales-Analytics.pbix): `Ecommerce-Sales-Analytics.pbix`

### Other components

- **Analyst**

## Connections

- Order items → Star schema: models as fact (evidence: `README.md`)
- Customer master → Star schema: joins dimension (evidence: `README.md`)
- Product catalog → Star schema: joins dimension (evidence: `README.md`)
- Flat order data → Flat-table model: models as flat table (evidence: `README.md`)
- Star schema → DAX measures: supports measures (evidence: `README.md`)
- Flat-table model → DAX measures: supports measures (evidence: `README.md`)
- Analyst → Executive overview: views report (evidence: `README.md`)
- DAX measures → Executive overview: reports metrics (evidence: `README.md`)
- DAX measures → Customer insights: reports metrics (evidence: `README.md`)
- DAX measures → Product performance: reports metrics (evidence: `README.md`)
- DAX measures → Profitability and returns: reports metrics (evidence: `README.md`)
- DAX measures → Delivery and logistics: reports metrics (evidence: `README.md`)
- DAX measures → Marketing and campaigns: reports metrics (evidence: `README.md`)
- Analyst → Customer insights: views report (evidence: `README.md`)
- Analyst → Product performance: views report (evidence: `README.md`)
- Analyst → Profitability and returns: views report (evidence: `README.md`)
- Analyst → Delivery and logistics: views report (evidence: `README.md`)
- Analyst → Marketing and campaigns: views report (evidence: `README.md`)
- Analyst → Overview cover: views report (evidence: `README.md`)
