Data Documentation
& Metric Definitions
Learn how to document data assets, write clear metric definitions, and build a single source of truth for business analytics.
What Is Data Documentation?
Data documentation is the practice of recording metadata, definitions, and context about every data asset in an organization. It answers three fundamental questions: What does this data mean? Where does it come from? and How should it be used?
Why Documentation Matters
Key Terms You Need to Know
Anatomy of a Metric Definition
The Golden Rule of Metrics
This is the reproducibility standard. If a definition is ambiguous, different reports will show different figures for the same metric, eroding stakeholder trust.
Achieving reproducibility requires specifying: the exact formula (including edge cases), the filters applied, the time grain (daily, weekly, monthly), and the source table or system.
Data Dictionary vs. Metric Definition
| Data Dictionary | Metric Definition | |
|---|---|---|
| Scope | Individual columns/fields | Business-level measures |
| Content | Name, type, allowed values | Formula, filters, grain, source |
| Audience | Data engineers, developers | Analysts, managers, executives |
| Example | order_date: DATE, not null | Revenue: \(\sum \text{sales} - \sum \text{returns}\) |
| Updates | When schema changes | When business logic evolves |
How to Write a Metric Definition
Example 1: Monthly Active Users
Example 2: Net Revenue
Example 3: Tracing Data Lineage
Building a Data Dictionary
| Column Name | Data Type | Description | Example |
|---|---|---|---|
| user_id | INTEGER | Unique user identifier | 10042 |
| signup_date | DATE | Date of account creation | 2024-03-15 |
| plan_type | VARCHAR | Subscription tier | premium |
| is_test | BOOLEAN | Internal test account flag | FALSE |
The Three Metadata Layers
The Documentation Lifecycle
Common Mistakes to Avoid
Documentation Summary
| Artifact | Contains | Primary Audience |
|---|---|---|
| Data Dictionary | Column names, types, allowed values | Engineers, developers |
| Metric Definition | Formula, filters, grain, source, owner | Analysts, executives |
| Data Lineage Map | Source → transform → destination flow | Data ops, quality team |
| Data Catalog | Searchable index of all documented assets | Everyone in the org |
| Change Log | History of definition changes with dates | Auditors, governance team |
Question 1 of 5
What is the primary purpose of a metric definition?
Question 2 of 5
Which of the following is NOT a required element in a complete metric definition?
Question 3 of 5
A company defines "Monthly Active Users" as "anyone who visited our website". Two analysts get different numbers. What is the most likely cause?
Question 4 of 5
A data dictionary is best described as:
Question 5 of 5
Which metadata layer would include information about pipeline refresh frequency and data quality scores?