Supplementary Figure 1

Logic algorithms were designed to account for predictable variation in coding behaviour among institutions as well as among coding systems.

(a) Logic algorithms for acute diverticulitis in ICD-10-AM (Australia).

Uncomplicated Diverticulitis = [K5732 (principal code) OR K5792 (principal code)] NOT ‘complicated diverticulitis (flag)’ NOT (C679, C785, C18, C19, C20, C763, K50, K51, K52 in any position)

Complicated Diverticulitis = {K5720 (principal code) OR K5722 (principal code) OR N321 (principal code) OR [N321 (2nd diagnostic code) AND K57 (principal code)] OR [N823 (principal code) AND K57 (2nd diagnostic code)] OR [N823 (2nd diagnostic code) AND K57 (principal code)] OR [N824 (principal code) AND K57 (2nd diagnostic code)] OR [N824 (2nd diagnostic code) AND K57 (principal code)] OR [K632 (principal code) AND K57 (2nd diagnostic code)] OR [K632 (2nd diagnostic code) AND K57 (principal code)] OR [({[K566 (principal code) AND K57 (2nd code)] OR [K566 (2nd code) AND K57 (principal code)]} AND (3203000, 3202400, 3202500, 3202600, 3200900, 3201200, 3037500, 3037501, 3037504, 3037528, OR 3037529)]} NOT (C679, C785, C18, C19, C20, C763, K50, K51, K52 in any position)

(b) Logic algorithms for ICD-10 (England).

Uncomplicated Diverticulitis = (K573 (principal code) OR K579 (principal code)] NOT ‘complicated diverticulitis (flag)’

NOT (K922 OR K625 per rectal bleeding in any position)

NOT (L71 (Therapeutic transluminal operations on other artery)

NOT (X331 (intraarterial blood transfusion) OR X332 (intravenous transfusion of packed cells) OR X338 (specified other blood transfusion) OR X339 (unspecified other blood transfusion))

NOT (H22, H23, H24, H25 in any position, colonoscopy)

NOT (C679, C785, C18, C19, C20, C763, K50, K51 in any position)

Complicated Diverticulitis = {K572 (principal code)

OR N321 (principal code)

OR [N321 (2nd diagnostic code) AND K57 (principal code)]

OR [N823 (principal code) AND K57 (2nd diagnostic code)]

OR [N823 (2nd diagnostic code) AND K57 (principal code)]

OR [N824 (principal code) AND K57 (2nd diagnostic code)]

OR [N824 (2nd diagnostic code) AND K57 (principal code)]

OR [K632 (principal code) AND K57 (2nd diagnostic code)]

OR [K632 (2nd diagnostic code) AND K57 (principal code)]

OR [({[K566 (principal code) AND K57 (2nd diagnostic code)] OR [K566 (2nd diagnostic code) AND K57 (principal code)]} AND (Colorectal Resection))]}

NOT (C679, C785, C18, C19, C20, C763, K50, K51 in any position)

(c) Logic algorithms for ICD-9-CM (USA).

Uncomplicated diverticulitis = 562.11 (principal diagnosis)

NOT ‘complicated diverticulitis (by flag)’

NOT 555 (regional enteritis – Crohn’s)

NOT 556 (ulcerative colitis)

NOT (153 (colonic malignancy), 154.1 (rectal malignancy), OR 197.5 (secondary malignant neoplasm of large intestine and rectum), in any position)

Complicated Diverticulitis ={[562.11 (principal or second diagnosis code)

AND (567.21, 567.22, 569.5, 569.81, 569.83, 596.1, 596.2, OR 619.1 (all principal or second diagnostic code))]

OR 596.1 (intestinovesical fistula principal position)

OR [(562.11 (principal or secondary diagnosis code) AND [560.89 (other specified intestinal obstruction, any position) OR 560.9 (unspecified intestinal obstruction, any position)]) AND (48.62, 48.63, 48.69, 45.75, 17.35, 45.76, 17.36, 45.79, 17.31, 17.39, 45.81, 45.82, 45.83, 46.01, 46.03,46.1, 46.2)]}

NOT 555 (regional enteritis – Crohn’s)

NOT 556 (ulcerative colitis)

NOT (153 (colonic malignancy), 154.1 (rectal malignancy), OR 197.5 (secondary malignant neoplasm of large intestine and rectum), 188 (bladder malignancy) in any position)

Supplementary Figure 2

(a)  The effect of the logic algorithm for uncomplicated diverticulitis in England was studied on a cohort from the Dr Foster Global Comparators Dataset 2007-2013. The diagram shows progressive filtering out of cases associated with bleeding through exclusion by secondary codes. The assumptions were that admissions for diverticular bleeding were also coded with additional secondary diagnostic codes related to per rectal bleeding, patients with severe diverticular bleeding underwent colonic vessel angioembolisation, patients with acute uncomplicated diverticulitis did not receive blood transfusion and that colonoscopy was not performed in patients with acute uncomplicated diverticulitis during the index admission.

(b)  The effect of the logic algorithm for defining complicated diverticulitis from acute diverticulitis in USA was studied on a cohort from the Dr Foster Global Comparators Dataset 2007-2013

Supplementary Table 1

(a) Procedure codes for acute diverticulitis from ACHI (Australia)

Operation for Acute Diverticulitis / ACHI Code / Code Description
Hartmann’s Procedure / 3203000
3203001 / Rectosigmoidectomy with formation of stoma
Laparoscopic rectosigmoidectomy with formation of stoma
Anterior Resection / 9220800
3202400
3202500
3202600
3202800
3206000 / Anterior resection (unspecified)
High anterior resection of rectum
Low anterior resection of rectum
Ultra low anterior resection of rectum
Ultra low anterior resection of rectum with hand sutured coloanal anastomosis
Restorative proctectomy
Left Hemicolectomy / 3200600
3200601
3200602
3200603 / Left hemicolectomy with anastomosis
Left hemicolectomy with formation of stoma
Laparoscopic left hemicolectomy with anastomosis
Laparoscopic left hemicolectomy with formation of stoma
Right Hemicolectomy / 3200001
3200003
3200301
3200303
3051503
3051504
3051505
3051506 / Right hemicolectomy with formation of stoma
Laparoscopic right hemicolectomy with formation of stoma
Right hemicolectomy with anastomosis
Laparoscopic right hemicolectomy with anastomosis
Ileocolic resection with anastomosis
Laparoscopic ileocolic resection with anastomosis
Ileocolic resection with formation of stoma
Laparoscopic ileocolic resection with formation of stoma
Extended Right Hemicolectomy / 3200401
3200403
3200501
3200503 / Extended right hemicolectomy with formation of stoma
Laparoscopic extended right hemicolectomy with formation of stoma
Extended right hemicolectomy with anastomosis
Laparoscopic extended right hemicolectomy with anastomosis
Partial Colectomy / 3200000
3200002
3200300
3200302 / Limited excision of large intestine with formation of stoma
Laparoscopic limited excision of large intestine with formation of stoma
Limited excision of large intestine with anastomosis
Laparoscopic limited excision of large intestine with anastomosis
Subtotal Colectomy / 3200400
3200402
3200500
3200502 / Subtotal colectomy with formation of stoma
Laparoscopic subtotal colectomy with formation of stoma
Subtotal colectomy with anastomosis
Laparoscopic subtotal colectomy with anastomosis
Total Colectomy / 3200900
3200901
3201200
3201201 / Total colectomy with ileostomy
Laparoscopic total colectomy with ileostomy
Total colectomy with ileorectal anastomosis
Laparoscopic total colectomy with ileorectal anastomosis
Proctocolectomy / 3201500
3205100
3205101 / Total proctocolectomy with ileostomy
Total proctocolectomy with ileo-anal anastomosis
Total proctocolectomy with ileo-anal anastomosis and formation of temporary ileostomy
Laparotomy & Drainage of Abscess / 3039400
3039600
3040200 / Drainage of intraabdominal abscess
Debridement and lavage of peritoneal cavity
Drainage of retroperitoneal abscess
Oversew of Colonic Perforation / 3037510
3037525 / Suture of perforated ulcer
Suture of laceration of large intestine
Temporary Stoma / 3037500
3037501
3037504
3037528
3037529 / Caecostomy
Other enterostomy
Other colostomy
Temporary colostomy
Temporary ileostomy
Laparoscopic Washout / 3039000
3039401 / Laparoscopy
Laparoscopic drainage of intraabdominal abscess
Laparoscopic Colectomy / 3200002
3200302 / Laparoscopic limited excision of large intestine with formation of stoma
Laparoscopic limited excision of large intestine with anastomosis
Fistula Repair / 3038202
3038202
3559600
3559603
3702300
3702301
3703800
3703801
9034001 / Radical repair of enterocutaneous fistula of large intestine
Radical repair of enterocutaneous fistula of large intestine
Repair of rectovaginal fistula
Repair of other fistula of vagina
Laparoscopic closure of cutaneous vesical fistula
Closure of cutaneous vesical fistula
Laparoscopic closure of vesicointestinal fistula
Closure of vesicointestinal fistula
Closure of fistula of large intestine

(b) Procedure codes for acute diverticulitis from OPCS-4.7 (England)

Operation for Acute Diverticulitis / OPCS Code / Code Description
Hartmann’s Procedure / H335 / Rectosigmoidectomy and closure of rectal stump and exteriorisation of bowel
Anterior Resection / H332
H333
H334
H336 / Proctectomy and anastomosis of colon to anus
Anterior resection of rectum and anastomosis of colon to rectum using
staples
Anterior resection of rectum and anastomosis NEC
Anterior resection of rectum and exteriorisation of bowel
Left Hemicolectomy / H091
H092
H093
H094
H095
H098
H099 / Left hemicolectomy and end to end anastomosis of colon to rectum
Left hemicolectomy and end to end anastomosis of colon to colon
Left hemicolectomy and anastomosis NEC
Left hemicolectomy and ileostomy HFQ
Left hemicolectomy and exteriorisation of bowel NEC
Other specified excision of left hemicolon
Unspecified excision of left hemicolon
Right Hemicolectomy / H071
H072
H073
H074
H078
H079
/ Right hemicolectomy and end to end anastomosis of ileum to colon
Right hemicolectomy and side to side anastomosis of ileum to
transverse colon
Right hemicolectomy and anastomosis NEC
Right hemicolectomy and ileostomy HFQ
Other specified other excision of right hemicolon
Unspecified other excision of right hemicolon
Extended Right Hemicolectomy / H061
H062
H063
H064
H068
H069
/ Extended right hemicolectomy and end to end anastomosis
Extended right hemicolectomy and anastomosis of ileum to colon
Extended right hemicolectomy and anastomosis NEC
Extended right hemicolectomy and ileostomy HFQ
Other specified extended excision of right hemicolon
Unspecified extended excision of right hemicolon
Transverse Colectomy / H081
H082
H083
H084
H085
H088
H089
/ Transverse colectomy and end to end anastomosis
Transverse colectomy and anastomosis of ileum to colon
Transverse colectomy and anastomosis NEC
Transverse colectomy and ileostomy HFQ
Transverse colectomy and exteriorisation of bowel NEC
Other specified excision of transverse colon
Unspecified excision of transverse colon
Sigmoid Colectomy / H101
H102
H103
H104
H105
H108
H109
/ Sigmoid colectomy and end to end anastomosis of ileum to rectum
Sigmoid colectomy and anastomosis of colon to rectum
Sigmoid colectomy and anastomosis NEC
Sigmoid colectomy and ileostomy HFQ
Sigmoid colectomy and exteriorisation of bowel NEC
Other specified excision of sigmoid colon
Unspecified excision of sigmoid colon
Partial Colectomy / H111
H112
H113
H114
H115
H118
H119
H308
H309
/ Colectomy and end to end anastomosis of colon to colon NEC
Colectomy and side to side anastomosis of ileum to colon NEC
Colectomy and anastomosis NEC
Colectomy and ileostomy NEC
Colectomy and exteriorisation of bowel NEC
Other specified other excision of colon
Unspecified other excision of colon
Other specified other operations on colon
Unspecified other operations on colon
Subtotal Colectomy / H293
H294
H298
H299
/ Subtotal excision of colon and creation of colonic pouch and
anastomosis of colon to rectum
Subtotal excision of colon and creation of colonic pouch NEC
Other specified subtotal excision of colon
Unspecified subtotal excision of colon
Total Colectomy / H051
H052
H053
H058
H059
/ Total colectomy and anastomosis of ileum to rectum
Total colectomy and ileostomy and creation of rectal fistula HFQ
Total colectomy and ileostomy NEC
Other specified total excision of colon
Unspecified total excision of colon
Proctocolectomy / H041
H042
H043
H048
H049
H291
H292
/ Panproctocolectomy and ileostomy
Panproctocolectomy and anastomosis of ileum to anus and creation
of pouch HFQ
Panproctocolectomy and anastomosis of ileum to anus NEC
Other specified total excision of colon and rectum
Unspecified total excision of colon and rectum
Subtotal excision of colon and rectum and creation of colonic pouch
and anastomosis of colon to anus
Subtotal excision of colon and rectum and creation of colonic pouch NEC
Washout or Drainage of Abscess / H161
H305
H625
T341
T342
T343
T348
T349
T463
T468
T469 / Drainage of colon
Irrigation of colon
Irrigation of bowel NEC
Open drainage of subphrenic abscess
Open drainage of pelvic abscess
Open drainage of abdominal abscess NEC
Other specified open drainage of peritoneum
Unspecified open drainage of peritoneum
Irrigation of peritoneal cavity
Other specified other drainage of peritoneal cavity
Unspecified other drainage of peritoneal cavity
Stoma / H151
H152
H157
H158
H159
G741
G742
G743
/ Loop colostomy
End colostomy
Percutaneous endoscopic sigmoid colostomy
Other specified other exteriorisation of colon
Unspecified other exteriorisation of colon
Creation of continent ileostomy
Creation of temporary ileostomy
Creation of defunctioning ileostomy
Fistula Repair / M372
M375
P253 / Repair of vesicocolic fistula
Repair of fistula of bladder NEC
Repair of rectovaginal fistula
Other Laparotomies or Laparoscopies / T412
T413
T415
T418
T419
H628
H629
Y751
Y752
Y758
Y759
Y502 / Division of band of peritoneum
Freeing of adhesions of peritoneum
Freeing of extensive adhesions of peritoneum
Other specified other open operations on peritoneum
Unspecified other open operations on peritoneum
Other specified other operations on bowel
Unspecified other operations on bowel
Laparoscopically assisted approach to abdominal cavity
Laparoscopic approach to abdominal cavity NEC
Other specified minimal access to abdominal cavity
Unspecified minimal access to abdominal cavity
Laparotomy approach NEC

(c) Procedure codes for acute diverticulitis from ICD-9-CM (USA)

Operation for Acute Diverticulitis / ICD-9-CM Procedure Code / Code Description
Hartmann’s Procedure / 48.62 / Anterior resection of rectum with synchronous colostomy
Anterior Resection / 48.63
48.69 / Other anterior resection of rectum
Other (Partial proctectomy, Rectal resection NOS)
Left Hemicolectomy / 45.75
17.35 / Open and other left hemicolectomy
Laparoscopic left hemicolectomy
Right Hemicolectomy / 45.72
45.73
17.32
17.33 / Open and other cecectomy
Open and other right hemicolectomy
Laparoscopic Cecectomy
Laparoscopic right hemicolectomy
Extended Right Hemicolectomy
Transverse Colectomy / 45.74
17.34 / Open and other resection of transverse colon
Laparoscopic resection of transverse colon
Sigmoid Colectomy / 45.76
17.36 / Open and other sigmoidectomy
Laparoscopic sigmoidectomy
Partial Colectomy / 45.79
17.31
17.39 / Other and unspecified partial excision of large intestine
Laparoscopic multiple segmental resection of large intestine
Other laparoscopic partial excision of large intestine
Subtotal Colectomy
Total Colectomy / 45.81
45.82
45.83 / Laparoscopic total intra-abdominal colectomy
Open total intra-abdominal colectomy
Other and unspecified total intra-abdominal colectomy
Proctocolectomy
Washout or Drainage of Abscess / 54.0
54.19
54.25 / Incision of abdominal wall (abdo wall, extraperitoneal, retroperitoneal
abscess)
Other laparotomy (drainage of intraperitoneal abscess/haematoma)
Peritoneal lavage
Stoma / 46.01
46.02
46.03
46.04
46.1
46.2 / Exteriorization of small intestine
Resection of exteriorized segment of small intestine
Exteriorization of large intestine
Resection of exteriorized segment of large intestine
Colostomy
Ileostomy
Fistula Repair / 46.76
57.83
70.72 / Closure of fistula of large intestine
Repair of fistula involving bladder and intestine
Repair of colovaginal fistula
Other Laparotomies or Laparoscopies / 45.03
45.28
45.9
46.75
48.29
54.11
54.21
17.4 / Incision of large intestine
Other diagnostic procedures on large intestine
Intestinal anastomosis
Suture of laceration of large intestine
Other diagnostic procedures on rectum, rectosigmoid and perirectal tissue
Exploratory laparotomy
Laparoscopy
Robotic assisted procedures

Supplementary Table 2

Codes used to represent percutaneous abscess drainage