📈 Module 8

Business Intelligence & Reporting

⏱ 12 hoursIntermediate–Advanced6 topics
🎯 By the end: define meaningful KPIs, model data and write basic DAX in Power BI, build interactive dashboards in Tableau, automate formatted Excel reports with Python, schedule them to run unattended, and present data clearly to non-technical stakeholders within data-privacy rules.

Analysis only matters when it changes a decision. Business Intelligence (BI) is the craft of turning data into dashboards and reports that executives actually use. This module covers the enterprise tools — Power BI and Tableau — plus how to automate reporting and communicate like a trusted advisor.

1KPIs, metrics & framing the question

A KPI (Key Performance Indicator) is a metric tied to a goal. Good BI starts not with charts but with the question the business needs answered.

ConceptMeaning
Metricany number you can measure (e.g. page views)
KPIa metric that tracks a goal (e.g. monthly revenue vs target)
Leading indicatorpredicts the future (e.g. trial sign-ups)
Lagging indicatorconfirms the past (e.g. quarterly revenue)

A dashboard usually leads with a few headline KPIs, then a trend, then a breakdown:

REVENUERs 4.2LORDERS1,284AVG ORDER VALUERs 327Sales by regionRevenue trend
Headline KPIs on top; a comparison and a trend below — the classic executive layout.
Make KPIs SMART: Specific, Measurable, Achievable, Relevant, Time-bound — and always show a comparison (vs target, vs last period) so a number has meaning.
Key points
  • A KPI is a metric tied to a goal; start BI from the business question, not the chart.
  • Leading indicators predict; lagging indicators confirm — track both.
  • Show every KPI against a comparison (target or prior period) so it carries meaning.

2Power BI: data modelling & DAX

Power BI is Microsoft's BI tool. Two skills make you productive: modelling your tables into a star schema, and writing DAX measures.

Fact: Salesamount, qty, keysDim: DateDim: ProductDim: Customer
A star schema: one central fact table linked to descriptive dimension tables.
Total Sales = SUM ( Sales[Amount] )

Sales LY = CALCULATE ( [Total Sales], SAMEPERIODLASTYEAR ( Dates[Date] ) )

Sales YoY % = DIVIDE ( [Total Sales] - [Sales LY], [Sales LY] )
Measures vs columns: a DAX measure is calculated on the fly as users filter the report (fast, flexible); a calculated column is computed once per row and stored. For aggregations like totals and ratios, use measures.
Key points
  • Model data as a star schema: one fact table (events) linked to dimension tables (descriptions).
  • DAX measures (e.g. SUM, CALCULATE, DIVIDE) compute on the fly as users filter.
  • Use measures for totals and ratios; reserve calculated columns for per-row values.

3Tableau: dashboards & storytelling

Tableau is the other industry-standard BI tool, loved for fast, drag-and-drop exploration and polished dashboards.

The core workflow

  • Connect to data (a file, a database, or a published source).
  • Build worksheets by dragging fields onto Rows, Columns and Marks.
  • Calculated fields add new logic, e.g. Profit Ratio = SUM([Profit]) / SUM([Sales]).
  • Parameters let viewers change inputs (e.g. a Top-N slider) interactively.
  • Dashboards combine worksheets; Story points sequence them into a narrative.
Power BI vs Tableau? Both are excellent and the concepts transfer. Power BI is common in Microsoft/Excel-heavy organisations and is cheaper; Tableau is prized for visual polish and exploration. Learn the ideas — KPIs, modelling, interactivity — and you can use either.
Dashboards are products. Design for the audience: an executive wants three numbers and a trend; an analyst wants filters and detail. Build the view your reader actually needs, not everything you can fit.
Key points
  • Tableau workflow: connect → build worksheets → calculated fields → parameters → dashboard/story.
  • Calculated fields and parameters add logic and interactivity for viewers.
  • Power BI and Tableau share the same concepts — learn the ideas, switch tools freely.

4Automating Excel reports with Python

Many businesses still run on Excel. Instead of rebuilding a report by hand each week, generate it with Python — formatted, accurate and instant.

import pandas as pd

sales = pd.read_csv('sales.csv')
summary = sales.groupby('region', as_index=False)['amount'].sum()

# write a formatted, multi-sheet Excel workbook
with pd.ExcelWriter('weekly_report.xlsx', engine='xlsxwriter') as xl:
    sales.to_excel(xl, sheet_name='Raw', index=False)
    summary.to_excel(xl, sheet_name='Summary', index=False)

    book  = xl.book
    sheet = xl.sheets['Summary']
    money = book.add_format({'num_format': 'Rs #,##0', 'bold': True})
    sheet.set_column('B:B', 16, money)        # format the amount column

print('weekly_report.xlsx created')
▶ Output
weekly_report.xlsx created
Two libraries: xlsxwriter is great for creating richly formatted files (colours, number formats, even charts); openpyxl can also read and edit existing workbooks. Pandas' to_excel uses either under the hood.
Key points
  • pd.ExcelWriter writes multi-sheet, formatted Excel files programmatically.
  • xlsxwriter creates richly formatted workbooks; openpyxl also edits existing ones.
  • Automating a recurring report removes copy-paste errors and saves hours every week.

5Scheduling automated reports

The final step in automation is making a report run by itself on a schedule, so it lands in stakeholders' inboxes without you lifting a finger.

# Linux / macOS — cron: run report.py every Monday at 8:00 AM
0 8 * * 1  /usr/bin/python3 /home/analyst/report.py
:: Windows — Task Scheduler (one-time setup, then it repeats)
schtasks /Create /TN WeeklyReport /TR "python C:\reports\report.py" /SC WEEKLY /D MON /ST 08:00
Pattern for a hands-off report: (1) a script pulls fresh data, (2) builds the Excel/PDF, (3) emails it to the distribution list, then (4) the scheduler runs that script on a cadence. Cloud tools (GitHub Actions, Airflow, cron on a server) do the same at scale.
Make scheduled jobs robust: add error handling and logging, and have the job alert you if it fails — a silent broken report is worse than no report, because people keep trusting stale numbers.
Key points
  • Schedule scripts with cron (Linux/macOS) or Task Scheduler (Windows) to run reports unattended.
  • A full pipeline: pull data → build report → email it → scheduler triggers it on a cadence.
  • Add logging and failure alerts so a broken job never silently serves stale data.

6Stakeholder communication & data privacy

Your final, highest-paid skill is communication — turning analysis into a decision a non-technical leader can act on.

Lead with the answer

Use the pyramid principle: state the recommendation first, then the key reasons, then the supporting detail. Executives want the “so what” in the first sentence, not on slide 14.

  • Translate stats into business language: not “p = 0.01” but “we are confident this is a real ₹2L/month opportunity.”
  • One message per slide; a clear title that states the takeaway.
  • Anticipate the “why” and “what should we do” questions.

Handle data responsibly

PrincipleWhat it means for you
Data minimisationcollect/keep only what you actually need
Purpose limitationuse data only for the stated purpose
Anonymisationremove or mask personal identifiers (PII) before sharing
Consent & rightsrespect opt-outs and deletion requests
GDPR & privacy are part of the job. Regulations like GDPR (EU) and India's DPDP Act govern personal data. Never expose individuals' PII in a dashboard, aggregate where possible, and secure any file containing personal data. Trust is your profession's currency.
Key points
  • Lead with the recommendation (pyramid principle); translate statistics into business impact.
  • One message per slide, with a title that states the takeaway.
  • Follow privacy law (GDPR/DPDP): minimise, anonymise PII, respect consent, and secure personal data.

★ Hands-on Project — Executive KPI Dashboard

Build a polished, interactive executive dashboard (in Power BI, Tableau, or Streamlit) connected to a data source, plus an automated supporting report.

  1. Pick 3–5 headline KPIs that answer a real business question (e.g. revenue vs target, orders, AOV, repeat-rate).
  2. Model the data: a fact table (sales) linked to dimensions (date, product, region/customer).
  3. Build the dashboard: KPI cards on top, a trend line, and a breakdown bar — with at least two interactive filters.
  4. Add a calculated measure/field (e.g. YoY % growth or profit ratio) and show each KPI vs a comparison.
  5. Write a Python script that generates a formatted Excel summary of the same numbers with pd.ExcelWriter.
  6. Schedule the script (cron or Task Scheduler) to refresh weekly, with basic logging.
  7. Write a one-slide executive summary using the pyramid principle (recommendation first).
  8. Ensure no personal identifiers are exposed; aggregate where needed. Publish/share the dashboard and add it to your portfolio.

Ready to test yourself?

Take the module quiz. Score 70% or more to mark this module complete.

Start the quiz →

💡 Log in to save your progress and earn the certificate.