verification / datasets / 11-transparency-code-spend / VARIABLES.md

Dataset 11 — Variables: Transparency Code spend over £500

Scope note: these definitions are derived from a three-council sample (Adur & Worthing, Gloucestershire, Sefton). Each English council publishes its own schema, so full coverage of ~317 councils requires a per-council scrape and a per-council column mapping like the ones below. Nothing here should be assumed to generalise beyond the sampled files without inspecting each new council's headers.

Prerequisite: schema normalisation

Before any variable can be computed across councils, each file must be mapped to a common transaction schema. Sample-specific steps:

1. Extracted variables

Common transaction fields and where each council carries them:

Variable Adur & Worthing (all 3 files) Gloucestershire Sefton
payment_date Posted_Date Payment Date TRANSACTION DATE
supplier Supplier Supplier Name SUPPLIER
amount_gbp Amount (strip £/commas) Payment Amount (sign-flip) AMOUNT
service_area Department (+ DepartmentSubsection; blank on some rows) Service Area (+ Service Devison) DEPARTMENT
transaction_id Transaction_ID Transaction No — (none)
expense_type Expense_Type (often blank) / Procurement_Class_Type Expense Type (+ Expense Code) SUMMARY OF EXPENDITURE (+ ACCOUNT, COST CENTRE)
capital_revenue Capital\Revenue Capital / Revenue — (none)
council Entity (Adur / Worthing / Joint) constant per file constant per file

Present in only some councils (kept as optional columns, not part of the common schema): Adur & Worthing AP_Ac_Postcode (supplier postcode); Gloucestershire BVA COP, Service Division Code, Charity & Company Number, Industry, Account Group, Account Name, Comment.

Verified availability: all three councils have date, supplier, amount and a service-area field. Transaction ID and capital/revenue exist only for Adur & Worthing and Gloucestershire. Supplier postcode only for Adur & Worthing; company/charity number and sector classification only for Gloucestershire.

2. Constructed variables

All are computed per council per month (or pooled months) after normalisation. Supplier-level constructs depend on supplier-name normalisation quality; there is no shared supplier ID across councils (only Gloucestershire has an — often blank — company-number column).

3. Variable file index

Extracted:

Constructed: