The-Strategy-Unit / The-Strategy-Unit/nhp_data

Treatment/Investigation codes flipped in A&E "Is Discharged with No Treatment or Investigations"

Open
#276 1 comment 0 reactions 1 assignee View on GitHub

@tomjemmett is already working on this.

Since Sep 16, 2026.

bug priority: should
Dominant language
Python
Stars
2
Forks
3
Avg merge
17h 57m
Merged PRs (30d)
7

Description

https://github.com/The-Strategy-Unit/nhp_data/blob/cff9dde878359ee56671b588ded35cbcc09a5921/src/nhp/data/raw_data/aae.py#L64-L74

Code Treatment Investigation
22 Guidance/advice only Dental investigation
24 Tetanus None
99 None Other

should be

    df_treatments = (
        spark.read.table(table_names.hes_aae_treatments)
        .filter(~F.col("treatment").isin(["22", "99"])
        .select("aekey", "fyear", "procode3")
    )

    df_investigations = (
        spark.read.table(table_names.hes_aae_investigations)
        .filter(F.col("investigation") != "24")
        .select("aekey", "fyear", "procode3")
    )

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.