Data dictionary

What the source data contains and what indicators are created.

This page explains the information used by the portfolio demo in business terms, so the analysis can be understood without reading the PySpark code.

Source data

The input is a synthetic quarterly financial-services portfolio. Each row represents one entity in one quarter.

Entity and segmentation fields

  • company_id, company: unique entity identifiers.
  • sector: Banking, Lending, Payments, Insurance or Asset Management.
  • country: geography used for portfolio context.
  • year, quarter: time dimension used to analyse evolution.
  • credit_rating: simplified external/internal credit quality band.

Financial statement fields

  • revenue, EBITDA, net income: operating scale and profitability.
  • assets, liabilities, debt, cash: balance-sheet strength and leverage.
  • current assets/liabilities: short-term liquidity position.
  • interest expense: cost of servicing debt.
  • operating cash flow and capex: cash generation and investment needs.
  • exposure: financial amount at stake for prioritisation.

Created indicators

PySpark converts raw fields into interpretable financial signals. These are the variables used by the cards, charts, watchlist and model.

Performance and trend

  • Revenue growth: quarter-on-quarter change in revenue.
  • EBITDA margin: profitability relative to revenue.
  • Margin delta: change in margin versus the previous quarter.
  • Deterioration flag: detects worsening margin, leverage or interest coverage.

Debt and liquidity

  • Net debt / EBITDA: leverage after considering cash.
  • Debt / EBITDA: gross leverage pressure.
  • Interest coverage: ability to service debt from EBITDA.
  • Current ratio: short-term liquidity buffer.
  • Free cash flow margin: cash generation after capex.

Risk and prioritisation

  • Financial Stress Score: 0-100 score combining leverage, liquidity, profitability, coverage and growth.
  • Risk tier: Low, Medium or High based on the stress score.
  • Risk drivers: plain-language reasons behind each alert.
  • Exposure at risk: exposure attached to high-risk entities.

Predictive layer

  • ML risk probability: Spark ML probability of financial distress.
  • AUC, precision, recall: validation metrics from a train/test split.
  • Sector/rating summaries: aggregated views that resemble stakeholder reporting.