Dataset Guide — Sales Dashboard¶
Source¶
Dataset: Superstore Sales (Sample - Superstore)
URL: https://www.kaggle.com/datasets/vivek468/superstore-dataset-final
File: Sample - Superstore.csv
Size: ~9,994 rows × 21 columns
Period: 4 years of orders
Column Descriptions¶
| Column | Type | Description |
|---|---|---|
Row ID |
int | Unique row identifier |
Order ID |
str | Order identifier (e.g., CA-2017-152156) |
Order Date |
date | When the order was placed |
Ship Date |
date | When the order shipped |
Ship Mode |
str | Standard, Second, First Class, Same Day |
Customer ID |
str | Unique customer identifier |
Customer Name |
str | Customer full name |
Segment |
str | Consumer, Corporate, Home Office |
Country |
str | Country (United States) |
City |
str | City |
State |
str | US state |
Postal Code |
int | ZIP code |
Region |
str | West, East, Central, South |
Product ID |
str | Unique product identifier |
Category |
str | Furniture, Office Supplies, Technology |
Sub-Category |
str | Bookcases, Chairs, Phones, Binders, etc. (17 total) |
Product Name |
str | Full product name |
Sales |
float | Revenue from the line item ($) |
Quantity |
int | Units ordered |
Discount |
float | Discount applied (0.0 to 0.8) |
Profit |
float | Profit from the line item ($) — can be negative! |
Key Data Characteristics¶
- One row per line item, not per order. An order with 3 products = 3 rows sharing the same
Order ID. - Profit can be negative — heavily discounted items sometimes sell at a loss. This is a key insight to surface.
- Date format may need parsing depending on locale (US format: MM/DD/YYYY).
- No missing values in the standard version — but always verify.
Useful Derived Columns¶
| New Column | Calculation | Why |
|---|---|---|
Profit Margin |
Profit / Sales |
Compare profitability across categories |
Shipping Days |
Ship Date - Order Date |
Operational efficiency |
Order Year |
YEAR(Order Date) |
Year-over-year analysis |
Order Month |
Order Date truncated to month |
Monthly trends |
Is Profitable |
Profit > 0 |
Flag loss-making line items |
Quick Exploration¶
import pandas as pd
df = pd.read_csv("Sample - Superstore.csv", encoding="latin-1",
parse_dates=["Order Date", "Ship Date"])
print(df.shape) # (9994, 21)
# Revenue and profit by category
print(df.groupby("Category")[["Sales", "Profit"]].sum().round(0))
# Sales Profit
# Furniture 742000 18451
# Office Supplies 719047 122491
# Technology 836154 145455
# Note: Furniture has high sales but low profit — a key finding
print(df.groupby("Category").apply(lambda x: (x["Profit"].sum() / x["Sales"].sum())))
# Furniture 0.025 ← only 2.5% margin!
# Office Supplies 0.170
# Technology 0.174
The headline finding is already visible
Furniture generates 32% of revenue but only 7% of profit — a 2.5% margin vs 17% for the other categories. This is the story the dashboard needs to surface.
Encoding Note¶
This dataset often needs encoding="latin-1"
The Superstore CSV contains special characters that break UTF-8 parsing. If you get a UnicodeDecodeError, use pd.read_csv("file.csv", encoding="latin-1").