SlideShare a Scribd company logo
1 of 34
Download to read offline
1
KPIs for e-commerce startups
Dr. Martin Loetzsch, Project A

@martin_loetzsch
2
http://commerce-reporting.com
3
KPIs?
4
KPIs = Aggregations over individual entities
5
▪
▪
▪ All time orders?
▪ Revenue October 1st?
▪ Sales by product?
▪ Allowed query operations
▪ Aggregations (count, distinct-count, sum, avg)
▪ Filtering
▪ Grouping
item
id
order
id
has
voucher
price day product
1 1 20 09-30 Cat
2 1 10 09-30 Dog
3 2 2 20 09-30 Cat
4 3 30 09-30 Cow
5 4 4 10 10-01 Dog
6 4 4 30 10-01 Cow
# Sold items: count(item_id)
# Orders: distinct-count(order_id)
# Orders with vouchers: distinct-count(has_voucher)
Revenue: sum(price)
Avg basket value [Revenue] / [# Orders]
SELECT count(distinct order_id) FROM order_item;
SELECT sum(price) FROM order_item WHERE day = ’10-01';
SELECT count(item_id) FROM order_item GROUP BY product;
Dimensional modelling
6
▪ Move redundant categorial data to “dimension” tables
order_item
item_id
order_id
has_voucher
price
day_fk
product_fk
day
day_id
day_name
month_id
month_name
product
product_id
product_name
item
id
order
id
has
voucher
price
day produc
t
1 1 20 930 1
2 1 10 930 2
3 2 2 20 930 1
4 3 30 930 3
5 4 4 10 1001 2
6 4 4 30 1001 3
day
id
day
name
month
id
month
name
930 09-30 9 Sep
1001 10-01 10 Oct
product
id
product
name
1 Cat
2 Dog
3 Cow
Analysis entities
7
orders
users
products
price 

histories
emails
clicks
…
…
operation

events
Customers
8
Customer metrics & attributes
9
▪ Customer
▪ Name, phone, email, gender, age, location, company
▪ Take data protection seriously!
▪ Categorization
▪ Customer type/ group / segment / cluster (B2B vs B2C,
frequent buyer, etc)
▪ Profession, Industry, Company size
▪ Newsletter subscription status, marketing opt-in
▪ Time
▪ Registration date, First touchpoint date, First order date,
Last order date, Last touchpoint date
▪ Time since last order, time since X, time from X to Y
▪ Purchase behavior
▪ # Orders lifetime, Revenue lifetime
▪ # Orders first 6 months, Revenue first 6 months
▪ # Orders last 6 months, Revenue last 6 months
▪ # Orders predicted, Revenue predicted
▪ Revenue group
▪ First product, Last product, Most bought product, 2nd most
bought product, 3rd most bought product
▪ First category, Last category, Most bought category, 2nd
most bought category, 3rd most bought category
▪ Order frequency & recency
▪ # Paused subscriptions, last NPS
Customer metrics & attributes II
10
▪ Marketing / On-site behavior:
▪ # Visits, Avg. number of page views per visit
▪ First touchpoint channel / partner / campaign etc.
▪ First page, Last page, First product, Last product
▪ First viewed product / category, Last viewed product /
category, Most frequently viewed product / category
▪ # Visits since last order
▪ Sales
▪ Lifecycle status, Funnel status
▪ Sales agent, account manager
▪ # Sales contacts
▪ Time X to Y

▪ Operations
▪ # Cancelled orders, # Returned orders, % Cancelled orders,
etc
▪ # Unpaid orders, Open balance
▪ Fraud status, scores
▪ Average NPS, last complaint
11
12
Orders (order items)
13
Order item metrics & attributes
14
▪ Time
▪ Order date, Payment date, Accounting date, Customer
registration date
▪ Time since X

▪ Who
▪ All customer attributes
▪ Order rank

▪ What
▪ All product attributes
▪ Vouchers
▪ Subscription information
▪ Operations
▪ Payment method & provider
▪ Status (payment & logistics), Cancellation reason, return
reason.
▪ Actual delivery time, promised delivery time,
▪ NPS
▪ Counting
▪ # Orders, # Items, # Unique products
▪ # First orders, # Second orders, # Second or subsequent
orders
▪ # B2B orders
▪ # Items returned, # Orders completely returned, # Orders
only partially returned
15
16
17
Margin structure a.k.a. Margensalat
18
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
VAT
gross
revenue
+
+
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
VAT
gross
revenue
+
+
net discount 

amount
net revenue
after discounts
+
-
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
VAT
gross
revenue
+
+
net discount 

amount
net revenue
after discounts
+
-
CM 1
+
purchase

cost
..
product
cost
+ +
-
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
VAT
gross
revenue
+
+
net discount 

amount
net revenue
after discounts
+
-
CM 1
+
purchase

cost
..
product
cost
+ +
-
payment

cost
fulfillment

cost
cost
of sales
CM 2a
+
+ +
-
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
VAT
gross
revenue
+
+
net discount 

amount
net revenue
after discounts
+
-
CM 1
+
purchase

cost
..
product
cost
+ +
-
payment

cost
fulfillment

cost
cost
of sales
CM 2a
+
+ +
-
return
cost
CM 2b+ -
Margin structure a.k.a. Margensalat
18
net shipping 

revenue
net product 

revenue
net

revenue
++
VAT
gross
revenue
+
+
net discount 

amount
net revenue
after discounts
+
-
CM 1
+
purchase

cost
..
product
cost
+ +
-
payment

cost
fulfillment

cost
cost
of sales
CM 2a
+
+ +
-
return
cost
CM 2b+ -
marketing
cost
CM3+ -
Touchpoints, Operations, Products, Sales
19
Consistency
20
Consistency: Conceptual challenge
21
▪ Similar sounding things in different domains
▪ If they are the same, call them the same
▪ If a non-trivial transformation happened between
cubes, then clearly mark it
▪ Find the right domain for a concept and then transfer
orders
users
clicks
# orders
# orders
# orders
Consistency: Technical challenge
22
▪ Single source of truth ▪ Avoid duplicating business logic
application
databases
json files
csv files
apis
reporting
crm
marketing
…
search
pricing
DWH
SELECT sum(total_price) AS revenue
FROM os_data.order
WHERE status IN ('pending', 'accepted', 'completed',
'proposal_for_change');
SELECT CASE WHEN (o.status <> 'started'
AND o.payment_status = 'authorised'
AND o.order_type <> 'backend')
THEN o.order_id END AS processed_order_fk
FROM os_data.order;
SELECT (last_status = 'pending') :: INTEGER
AS is_unprocessed
FROM os_data.order;
Consistent dashboards
23
▪ Contribution margin 3a ▪ Use schemas between reporting and database
▪ Mondrian
▪ LookerML
▪ your own
▪ Or: Pre-compute metrics in database
SELECT
order_item_id,
((((((COALESCE(item_net_price, 0) :: REAL
+ COALESCE(net_shipping_revenue, 0) :: REAL)
- ((COALESCE(item_net_purchase_price, 0) :: REAL
+ COALESCE(alcohol_tax, 0) :: REAL)
+ COALESCE(import_tax, 0) :: REAL))
- (COALESCE(net_fulfillment_costs, 0) :: REAL
+ COALESCE(net_payment_costs, 0) :: REAL))
- COALESCE(net_return_costs, 0) :: REAL)
- ((COALESCE(item_net_price, 0) :: REAL
+ COALESCE(net_shipping_revenue, 0) :: REAL)
- ((((COALESCE(item_net_price, 0) :: REAL
+ COALESCE(item_tax_amount, 0) :: REAL)
+ COALESCE(gross_shipping_revenue, 0) :: REAL)
- COALESCE(voucher_gross_amount, 0) :: REAL)
* (1 - ((COALESCE(item_tax_amount, 0) :: REAL
+ (COALESCE(gross_shipping_revenue, 0) :: REAL
- COALESCE(net_shipping_revenue, 0) :: REAL))
/ NULLIF(((COALESCE(item_net_price, 0) :: REAL
+ COALESCE(item_tax_amount, 0) :: REAL)
+ COALESCE(gross_shipping_revenue, 0) :: REAL), 0))))))
- COALESCE(goodie_cost_per_item, 0) :: REAL) :: DOUBLE PRECISION
AS "Contribution margin 3a"
FROM dim.sales_fact;
Correctness
24
▪ Do tests
SELECT util.assert_equal(
'The number of orders in the data table should equal the number of orders in the dim table',
'SELECT COUNT(DISTINCT order_id)
FROM os_data.sold_item
WHERE order_item_price > 0;',
'SELECT COUNT(order_id)
FROM os_dim.order;');
SELECT util.assert_almost_equal(
'The sum of prices in the dim table should equal the sum of prices in the data table',
'SELECT sum(order_item_price * order_item_quantity)
FROM os_data.sold_item
WHERE order_item_price > 0
AND coalesce( spryker_order_id, '''') NOT LIKE ''CH%'';',
'SELECT sum(net_product_value + tax_amount_product)
FROM os_dim.order
JOIN os_dim.sales_country ON sales_country_id = sales_country_fk
WHERE sales_country_name <> ''CH'';', 1);
SELECT util.assert_equal(
'The number of orders in the data table should equal the number of orders in the dim table',
http://commerce-reporting.com
25
Work with us
26
▪ https://www.project-a.com/en/career/jobs
▪ Director of Business Intelligence
▪ Produkt Manager Business Intelligence
▪ Data Engineer / Data Scientist
27
Thank you
@martin_loetzsch

More Related Content

Similar to KPIs for e-commerce startups

AGS Support Live SAP Business One Order to Cash
AGS Support Live SAP Business One Order to Cash AGS Support Live SAP Business One Order to Cash
AGS Support Live SAP Business One Order to Cash AGSanePLDTCompany
 
The Nine Numbers™ You Need to Know for Business Success
The Nine Numbers™ You Need to Know for Business SuccessThe Nine Numbers™ You Need to Know for Business Success
The Nine Numbers™ You Need to Know for Business SuccessDennis Anderson
 
Fundamentals of business & financial analysis
Fundamentals of business & financial analysis Fundamentals of business & financial analysis
Fundamentals of business & financial analysis Aida Makas
 
Inventory Management Solutions from satiate
Inventory Management Solutions from satiateInventory Management Solutions from satiate
Inventory Management Solutions from satiateRahman A
 
Maximizing QuickBooks
Maximizing QuickBooksMaximizing QuickBooks
Maximizing QuickBooksLean Teams
 
Brazilian Ecommerce OLIST Market Data Analysis
Brazilian Ecommerce OLIST Market Data AnalysisBrazilian Ecommerce OLIST Market Data Analysis
Brazilian Ecommerce OLIST Market Data Analysiskaushikdey53
 
Quantify resonate slides
Quantify resonate slidesQuantify resonate slides
Quantify resonate slidesCaroline Powell
 
LivaBudget & LivaClick (Best Business Solutions CPM & BI)
LivaBudget & LivaClick (Best Business Solutions CPM & BI)LivaBudget & LivaClick (Best Business Solutions CPM & BI)
LivaBudget & LivaClick (Best Business Solutions CPM & BI)DataLiva Bilişim Hizmetleri
 
Business valuation imec7 22-14-final
Business valuation imec7 22-14-finalBusiness valuation imec7 22-14-final
Business valuation imec7 22-14-finalGlen Birnbaum
 
How To Leverage Sage Software To Become A Data-Driven Organization
How To Leverage Sage Software To Become A Data-Driven OrganizationHow To Leverage Sage Software To Become A Data-Driven Organization
How To Leverage Sage Software To Become A Data-Driven OrganizationGross, Mendelsohn & Associates
 
Analytics Update from Tim Leighton-Boyce
Analytics Update from Tim Leighton-BoyceAnalytics Update from Tim Leighton-Boyce
Analytics Update from Tim Leighton-BoyceScreen Pages
 
Refresher Training_Inventory Management.pdf
Refresher Training_Inventory Management.pdfRefresher Training_Inventory Management.pdf
Refresher Training_Inventory Management.pdfAGSanePLDTCompany
 
Gestion de Inventario en Business Central
Gestion de Inventario en Business CentralGestion de Inventario en Business Central
Gestion de Inventario en Business CentralJuan Fabian
 
Understand orderwise payout report
Understand orderwise payout reportUnderstand orderwise payout report
Understand orderwise payout reportPaytm
 

Similar to KPIs for e-commerce startups (20)

Know your numbers
Know your numbersKnow your numbers
Know your numbers
 
AGS Support Live SAP Business One Order to Cash
AGS Support Live SAP Business One Order to Cash AGS Support Live SAP Business One Order to Cash
AGS Support Live SAP Business One Order to Cash
 
The Nine Numbers™ You Need to Know for Business Success
The Nine Numbers™ You Need to Know for Business SuccessThe Nine Numbers™ You Need to Know for Business Success
The Nine Numbers™ You Need to Know for Business Success
 
Fundamentals of business & financial analysis
Fundamentals of business & financial analysis Fundamentals of business & financial analysis
Fundamentals of business & financial analysis
 
Basics of sap sd module
Basics of sap sd moduleBasics of sap sd module
Basics of sap sd module
 
Inventory Management Solutions from satiate
Inventory Management Solutions from satiateInventory Management Solutions from satiate
Inventory Management Solutions from satiate
 
Maximizing QuickBooks
Maximizing QuickBooksMaximizing QuickBooks
Maximizing QuickBooks
 
Chapter # 13
Chapter # 13Chapter # 13
Chapter # 13
 
Brazilian Ecommerce OLIST Market Data Analysis
Brazilian Ecommerce OLIST Market Data AnalysisBrazilian Ecommerce OLIST Market Data Analysis
Brazilian Ecommerce OLIST Market Data Analysis
 
Quantify resonate slides
Quantify resonate slidesQuantify resonate slides
Quantify resonate slides
 
LivaBudget & LivaClick (Best Business Solutions CPM & BI)
LivaBudget & LivaClick (Best Business Solutions CPM & BI)LivaBudget & LivaClick (Best Business Solutions CPM & BI)
LivaBudget & LivaClick (Best Business Solutions CPM & BI)
 
Business valuation imec7 22-14-final
Business valuation imec7 22-14-finalBusiness valuation imec7 22-14-final
Business valuation imec7 22-14-final
 
Bake for profit step 3
Bake for profit   step 3Bake for profit   step 3
Bake for profit step 3
 
How To Leverage Sage Software To Become A Data-Driven Organization
How To Leverage Sage Software To Become A Data-Driven OrganizationHow To Leverage Sage Software To Become A Data-Driven Organization
How To Leverage Sage Software To Become A Data-Driven Organization
 
Tally jankari
Tally jankariTally jankari
Tally jankari
 
Analytics Update from Tim Leighton-Boyce
Analytics Update from Tim Leighton-BoyceAnalytics Update from Tim Leighton-Boyce
Analytics Update from Tim Leighton-Boyce
 
Refresher Training_Inventory Management.pdf
Refresher Training_Inventory Management.pdfRefresher Training_Inventory Management.pdf
Refresher Training_Inventory Management.pdf
 
Gestion de Inventario en Business Central
Gestion de Inventario en Business CentralGestion de Inventario en Business Central
Gestion de Inventario en Business Central
 
Understand orderwise payout report
Understand orderwise payout reportUnderstand orderwise payout report
Understand orderwise payout report
 
Tally Features
Tally FeaturesTally Features
Tally Features
 

More from Martin Loetzsch

Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?
Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?
Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?Martin Loetzsch
 
Project A Data Modelling Best Practices Part I: How to model data in a data w...
Project A Data Modelling Best Practices Part I: How to model data in a data w...Project A Data Modelling Best Practices Part I: How to model data in a data w...
Project A Data Modelling Best Practices Part I: How to model data in a data w...Martin Loetzsch
 
Data infrastructure for the other 90% of companies
Data infrastructure for the other 90% of companiesData infrastructure for the other 90% of companies
Data infrastructure for the other 90% of companiesMartin Loetzsch
 
Lightweight ETL pipelines with mara (PyData Berlin September Meetup)
Lightweight ETL pipelines with mara (PyData Berlin September Meetup)Lightweight ETL pipelines with mara (PyData Berlin September Meetup)
Lightweight ETL pipelines with mara (PyData Berlin September Meetup)Martin Loetzsch
 
Data Warehousing with Python
Data Warehousing with PythonData Warehousing with Python
Data Warehousing with PythonMartin Loetzsch
 
ETL Patterns with Postgres
ETL Patterns with PostgresETL Patterns with Postgres
ETL Patterns with PostgresMartin Loetzsch
 

More from Martin Loetzsch (6)

Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?
Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?
Project A Data Modelling Best Practices Part II: How to Build a Data Warehouse?
 
Project A Data Modelling Best Practices Part I: How to model data in a data w...
Project A Data Modelling Best Practices Part I: How to model data in a data w...Project A Data Modelling Best Practices Part I: How to model data in a data w...
Project A Data Modelling Best Practices Part I: How to model data in a data w...
 
Data infrastructure for the other 90% of companies
Data infrastructure for the other 90% of companiesData infrastructure for the other 90% of companies
Data infrastructure for the other 90% of companies
 
Lightweight ETL pipelines with mara (PyData Berlin September Meetup)
Lightweight ETL pipelines with mara (PyData Berlin September Meetup)Lightweight ETL pipelines with mara (PyData Berlin September Meetup)
Lightweight ETL pipelines with mara (PyData Berlin September Meetup)
 
Data Warehousing with Python
Data Warehousing with PythonData Warehousing with Python
Data Warehousing with Python
 
ETL Patterns with Postgres
ETL Patterns with PostgresETL Patterns with Postgres
ETL Patterns with Postgres
 

Recently uploaded

April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysismanisha194592
 
Call Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night StandCall Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night Standamitlee9823
 
Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxolyaivanovalion
 
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...amitlee9823
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangaloreamitlee9823
 
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...karishmasinghjnh
 
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...amitlee9823
 
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...amitlee9823
 
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...amitlee9823
 
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...amitlee9823
 
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...amitlee9823
 
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% SecureCall me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% SecurePooja Nehwal
 
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightCheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightDelhi Call girls
 
➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men 🔝Thrissur🔝 Escor...
➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men  🔝Thrissur🔝   Escor...➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men  🔝Thrissur🔝   Escor...
➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men 🔝Thrissur🔝 Escor...amitlee9823
 
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...amitlee9823
 
BDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort Service
BDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort ServiceBDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort Service
BDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort ServiceDelhi Call girls
 

Recently uploaded (20)

April 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's AnalysisApril 2024 - Crypto Market Report's Analysis
April 2024 - Crypto Market Report's Analysis
 
Call Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night StandCall Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night Stand
Call Girls In Nandini Layout ☎ 7737669865 🥵 Book Your One night Stand
 
Anomaly detection and data imputation within time series
Anomaly detection and data imputation within time seriesAnomaly detection and data imputation within time series
Anomaly detection and data imputation within time series
 
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
(NEHA) Call Girls Katra Call Now 8617697112 Katra Escorts 24x7
 
Midocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFxMidocean dropshipping via API with DroFx
Midocean dropshipping via API with DroFx
 
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men  🔝mahisagar🔝   Esc...
➥🔝 7737669865 🔝▻ mahisagar Call-girls in Women Seeking Men 🔝mahisagar🔝 Esc...
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
 
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
👉 Amritsar Call Girl 👉📞 6367187148 👉📞 Just📲 Call Ruhi Call Girl Phone No Amri...
 
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
 
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
 
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
Escorts Service Kumaraswamy Layout ☎ 7737669865☎ Book Your One night Stand (B...
 
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Indiranagar Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
 
Abortion pills in Jeddah | +966572737505 | Get Cytotec
Abortion pills in Jeddah | +966572737505 | Get CytotecAbortion pills in Jeddah | +966572737505 | Get Cytotec
Abortion pills in Jeddah | +966572737505 | Get Cytotec
 
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
 
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% SecureCall me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
 
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightCheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
 
➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men 🔝Thrissur🔝 Escor...
➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men  🔝Thrissur🔝   Escor...➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men  🔝Thrissur🔝   Escor...
➥🔝 7737669865 🔝▻ Thrissur Call-girls in Women Seeking Men 🔝Thrissur🔝 Escor...
 
Call Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts Service
Call Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts ServiceCall Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts Service
Call Girls In Shalimar Bagh ( Delhi) 9953330565 Escorts Service
 
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men  🔝malwa🔝   Escorts Ser...
➥🔝 7737669865 🔝▻ malwa Call-girls in Women Seeking Men 🔝malwa🔝 Escorts Ser...
 
BDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort Service
BDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort ServiceBDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort Service
BDSM⚡Call Girls in Mandawali Delhi >༒8448380779 Escort Service
 

KPIs for e-commerce startups

  • 1. 1 KPIs for e-commerce startups Dr. Martin Loetzsch, Project A
 @martin_loetzsch
  • 2. 2
  • 5. KPIs = Aggregations over individual entities 5 ▪ ▪ ▪ All time orders? ▪ Revenue October 1st? ▪ Sales by product? ▪ Allowed query operations ▪ Aggregations (count, distinct-count, sum, avg) ▪ Filtering ▪ Grouping item id order id has voucher price day product 1 1 20 09-30 Cat 2 1 10 09-30 Dog 3 2 2 20 09-30 Cat 4 3 30 09-30 Cow 5 4 4 10 10-01 Dog 6 4 4 30 10-01 Cow # Sold items: count(item_id) # Orders: distinct-count(order_id) # Orders with vouchers: distinct-count(has_voucher) Revenue: sum(price) Avg basket value [Revenue] / [# Orders] SELECT count(distinct order_id) FROM order_item; SELECT sum(price) FROM order_item WHERE day = ’10-01'; SELECT count(item_id) FROM order_item GROUP BY product;
  • 6. Dimensional modelling 6 ▪ Move redundant categorial data to “dimension” tables order_item item_id order_id has_voucher price day_fk product_fk day day_id day_name month_id month_name product product_id product_name item id order id has voucher price day produc t 1 1 20 930 1 2 1 10 930 2 3 2 2 20 930 1 4 3 30 930 3 5 4 4 10 1001 2 6 4 4 30 1001 3 day id day name month id month name 930 09-30 9 Sep 1001 10-01 10 Oct product id product name 1 Cat 2 Dog 3 Cow
  • 9. Customer metrics & attributes 9 ▪ Customer ▪ Name, phone, email, gender, age, location, company ▪ Take data protection seriously! ▪ Categorization ▪ Customer type/ group / segment / cluster (B2B vs B2C, frequent buyer, etc) ▪ Profession, Industry, Company size ▪ Newsletter subscription status, marketing opt-in ▪ Time ▪ Registration date, First touchpoint date, First order date, Last order date, Last touchpoint date ▪ Time since last order, time since X, time from X to Y ▪ Purchase behavior ▪ # Orders lifetime, Revenue lifetime ▪ # Orders first 6 months, Revenue first 6 months ▪ # Orders last 6 months, Revenue last 6 months ▪ # Orders predicted, Revenue predicted ▪ Revenue group ▪ First product, Last product, Most bought product, 2nd most bought product, 3rd most bought product ▪ First category, Last category, Most bought category, 2nd most bought category, 3rd most bought category ▪ Order frequency & recency ▪ # Paused subscriptions, last NPS
  • 10. Customer metrics & attributes II 10 ▪ Marketing / On-site behavior: ▪ # Visits, Avg. number of page views per visit ▪ First touchpoint channel / partner / campaign etc. ▪ First page, Last page, First product, Last product ▪ First viewed product / category, Last viewed product / category, Most frequently viewed product / category ▪ # Visits since last order ▪ Sales ▪ Lifecycle status, Funnel status ▪ Sales agent, account manager ▪ # Sales contacts ▪ Time X to Y
 ▪ Operations ▪ # Cancelled orders, # Returned orders, % Cancelled orders, etc ▪ # Unpaid orders, Open balance ▪ Fraud status, scores ▪ Average NPS, last complaint
  • 11. 11
  • 12. 12
  • 14. Order item metrics & attributes 14 ▪ Time ▪ Order date, Payment date, Accounting date, Customer registration date ▪ Time since X
 ▪ Who ▪ All customer attributes ▪ Order rank
 ▪ What ▪ All product attributes ▪ Vouchers ▪ Subscription information ▪ Operations ▪ Payment method & provider ▪ Status (payment & logistics), Cancellation reason, return reason. ▪ Actual delivery time, promised delivery time, ▪ NPS ▪ Counting ▪ # Orders, # Items, # Unique products ▪ # First orders, # Second orders, # Second or subsequent orders ▪ # B2B orders ▪ # Items returned, # Orders completely returned, # Orders only partially returned
  • 15. 15
  • 16. 16
  • 17. 17
  • 18. Margin structure a.k.a. Margensalat 18
  • 19. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++
  • 20. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++ VAT gross revenue + +
  • 21. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++ VAT gross revenue + + net discount 
 amount net revenue after discounts + -
  • 22. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++ VAT gross revenue + + net discount 
 amount net revenue after discounts + - CM 1 + purchase
 cost .. product cost + + -
  • 23. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++ VAT gross revenue + + net discount 
 amount net revenue after discounts + - CM 1 + purchase
 cost .. product cost + + - payment
 cost fulfillment
 cost cost of sales CM 2a + + + -
  • 24. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++ VAT gross revenue + + net discount 
 amount net revenue after discounts + - CM 1 + purchase
 cost .. product cost + + - payment
 cost fulfillment
 cost cost of sales CM 2a + + + - return cost CM 2b+ -
  • 25. Margin structure a.k.a. Margensalat 18 net shipping 
 revenue net product 
 revenue net
 revenue ++ VAT gross revenue + + net discount 
 amount net revenue after discounts + - CM 1 + purchase
 cost .. product cost + + - payment
 cost fulfillment
 cost cost of sales CM 2a + + + - return cost CM 2b+ - marketing cost CM3+ -
  • 28. Consistency: Conceptual challenge 21 ▪ Similar sounding things in different domains ▪ If they are the same, call them the same ▪ If a non-trivial transformation happened between cubes, then clearly mark it ▪ Find the right domain for a concept and then transfer orders users clicks # orders # orders # orders
  • 29. Consistency: Technical challenge 22 ▪ Single source of truth ▪ Avoid duplicating business logic application databases json files csv files apis reporting crm marketing … search pricing DWH SELECT sum(total_price) AS revenue FROM os_data.order WHERE status IN ('pending', 'accepted', 'completed', 'proposal_for_change'); SELECT CASE WHEN (o.status <> 'started' AND o.payment_status = 'authorised' AND o.order_type <> 'backend') THEN o.order_id END AS processed_order_fk FROM os_data.order; SELECT (last_status = 'pending') :: INTEGER AS is_unprocessed FROM os_data.order;
  • 30. Consistent dashboards 23 ▪ Contribution margin 3a ▪ Use schemas between reporting and database ▪ Mondrian ▪ LookerML ▪ your own ▪ Or: Pre-compute metrics in database SELECT order_item_id, ((((((COALESCE(item_net_price, 0) :: REAL + COALESCE(net_shipping_revenue, 0) :: REAL) - ((COALESCE(item_net_purchase_price, 0) :: REAL + COALESCE(alcohol_tax, 0) :: REAL) + COALESCE(import_tax, 0) :: REAL)) - (COALESCE(net_fulfillment_costs, 0) :: REAL + COALESCE(net_payment_costs, 0) :: REAL)) - COALESCE(net_return_costs, 0) :: REAL) - ((COALESCE(item_net_price, 0) :: REAL + COALESCE(net_shipping_revenue, 0) :: REAL) - ((((COALESCE(item_net_price, 0) :: REAL + COALESCE(item_tax_amount, 0) :: REAL) + COALESCE(gross_shipping_revenue, 0) :: REAL) - COALESCE(voucher_gross_amount, 0) :: REAL) * (1 - ((COALESCE(item_tax_amount, 0) :: REAL + (COALESCE(gross_shipping_revenue, 0) :: REAL - COALESCE(net_shipping_revenue, 0) :: REAL)) / NULLIF(((COALESCE(item_net_price, 0) :: REAL + COALESCE(item_tax_amount, 0) :: REAL) + COALESCE(gross_shipping_revenue, 0) :: REAL), 0)))))) - COALESCE(goodie_cost_per_item, 0) :: REAL) :: DOUBLE PRECISION AS "Contribution margin 3a" FROM dim.sales_fact;
  • 31. Correctness 24 ▪ Do tests SELECT util.assert_equal( 'The number of orders in the data table should equal the number of orders in the dim table', 'SELECT COUNT(DISTINCT order_id) FROM os_data.sold_item WHERE order_item_price > 0;', 'SELECT COUNT(order_id) FROM os_dim.order;'); SELECT util.assert_almost_equal( 'The sum of prices in the dim table should equal the sum of prices in the data table', 'SELECT sum(order_item_price * order_item_quantity) FROM os_data.sold_item WHERE order_item_price > 0 AND coalesce( spryker_order_id, '''') NOT LIKE ''CH%'';', 'SELECT sum(net_product_value + tax_amount_product) FROM os_dim.order JOIN os_dim.sales_country ON sales_country_id = sales_country_fk WHERE sales_country_name <> ''CH'';', 1); SELECT util.assert_equal( 'The number of orders in the data table should equal the number of orders in the dim table',
  • 33. Work with us 26 ▪ https://www.project-a.com/en/career/jobs ▪ Director of Business Intelligence ▪ Produkt Manager Business Intelligence ▪ Data Engineer / Data Scientist