[
  {
    "phenotype_id": "PH101",
    "phenotype_version_id": 202,
    "name": "Anorectal fistula",
    "definition": "At the specified date, a patient is defined as having had 'Anorectal fistula' IF they meet the criteria for any of the following on or before the specified date. The earliest date on which the individual meets any of the following criteria on or before the specified date is defined as the first event date:\n\n\nPrimary care\n\n\n1. 'Anorectal fistula' diagnosis or history of diagnosis or procedure during a consultation \n\nOR\nSecondary care\n\n\n1. ALL diagnoses of 'Anorectal fistula' or history of diagnosis during a hospitalization\nOR\nSecondary care (OPCS4)\n\n\n1. ALL procedures for 'Anorectal fistula' during a hospitalization\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",
    "implementation": "",
    "publications": [
      {
        "doi": "10.1016/S2589-7500(19)30012-3",
        "details": "Kuan V., Denaxas S., Gonzalez-Izquierdo A. et al. A chronological map of 308 physical and mental health conditions from 4 million individuals in the National Health Service. The Lancet Digital Health - DOI 10.1016/S2589-7500(19)30012-3"
      }
    ],
    "validation": "",
    "citation_requirements": "",
    "created": "2021-10-06T16:03:04.395895Z",
    "author": "Kuan V, Denaxas S, Gonzalez-Izquierdo A, Direk K, Bhatti O, Husain S, Sutaria S, Hingorani M, Nitsch D, Parisinos C, Lumbers T, Mathur R, Sofat R, Casas JP, Wong I, Hemingway H, Hingorani A",
    "collections": [
      {
        "name": "CALIBER",
        "value": 21
      },
      {
        "name": "Phenotype Library",
        "value": 18
      }
    ],
    "tags": null,
    "organisation": null,
    "world_access": 1,
    "updated": "2021-10-06T16:03:04.395924Z",
    "sex": [
      {
        "name": "Both",
        "value": "3"
      }
    ],
    "type": [
      {
        "name": "Disease or syndrome",
        "value": "2"
      }
    ],
    "ontology": null,
    "phenoflowid": "https://kclhi.org/phenoflow/workflows/github.com/phenoflow/Anorectal-fistula---d3a38b50-175e-11ef-9de4-4d4ea830ad16/blob/read-potential-cases-fhir/Anorectal-fistula.cwl",
    "data_sources": [
      {
        "name": "CPRD GOLD",
        "value": 5,
        "uid": "a29feafa-7bdd-44e9-b977-c9d26425e67f",
        "url": "https://healthdatagateway.org/en/dataset/694",
        "datasource_id": 694
      },
      {
        "name": "HES Admitted Patient Care data for CPRD GOLD",
        "value": 9,
        "uid": "4bcf64a6-f404-4ef4-ae6e-172512ab5f43",
        "url": "https://healthdatagateway.org/en/dataset/674",
        "datasource_id": 674
      }
    ],
    "coding_system": [
      {
        "name": "ICD10 codes",
        "value": 4
      },
      {
        "name": "Read codes v2",
        "value": 5
      },
      {
        "name": "OPCS4 codes",
        "value": 7
      },
      {
        "name": "Med codes",
        "value": 8
      }
    ],
    "event_date_range": "01/01/1999 - 01/07/2016",
    "concept_information": [
      {
        "concept_id": 965,
        "concept_version_id": 3069,
        "concept_name": "Anorectal fistula - Primary care",
        "coding_system": {
          "id": 5,
          "name": "Read codes v2",
          "description": "Read codes v2"
        },
        "phenotype_id": "PH101",
        "phenotype_version_id": 202,
        "phenotype_name": "Anorectal fistula",
        "code_attribute_header": [
          "Disease",
          "Medcode",
          "Category"
        ],
        "codes": [
          {
            "code": "7729700.0",
            "description": "Closure of rectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "20885.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738000.0",
            "description": "Laying open of low anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "4994.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738100.0",
            "description": "Laying open of high anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "20959.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738.11",
            "description": "Anal fistula operations",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "18201.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738200.0",
            "description": "Laying open of anal fistula NEC",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "2406.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738300.0",
            "description": "Insertion seton in high anal fistula+part lay open track HFQ",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "19419.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738400.0",
            "description": "Fistulography of anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "18188.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738600.0",
            "description": "Excision of fistula in ano",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "7140.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738611.0",
            "description": "Excision of anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "4791.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "7738900.0",
            "description": "Repair of anal fistula using plug",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "97573.0",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "J53..00",
            "description": "Anal fissure and fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "1979.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J531.00",
            "description": "Fistula-in-ano",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "598.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J531000",
            "description": "Sub-mucosal anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "56271.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J531100",
            "description": "Inter-muscular anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "59127.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J531200",
            "description": "Ano-rectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "19952.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J531300",
            "description": "Rectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "15202.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J531z00",
            "description": "Fistula-in-ano NOS",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "37729.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "J53z.00",
            "description": "Anal fissure and fistula NOS",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Medcode": "15210.0",
              "Category": "Diagnosis of Anorectal fistula"
            }
          }
        ]
      },
      {
        "concept_id": 966,
        "concept_version_id": 3071,
        "concept_name": "Anorectal fistula - Primary care",
        "coding_system": {
          "id": 8,
          "name": "Med codes",
          "description": "Med codes"
        },
        "phenotype_id": "PH101",
        "phenotype_version_id": 202,
        "phenotype_name": "Anorectal fistula",
        "code_attribute_header": [
          "Disease",
          "ReadcodeDescr",
          "Readcode"
        ],
        "codes": [
          {
            "code": "15202.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Rectal fistula",
              "Readcode": "J531300"
            }
          },
          {
            "code": "15210.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Anal fissure and fistula NOS",
              "Readcode": "J53z.00"
            }
          },
          {
            "code": "18188.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Fistulography of anal fistula",
              "Readcode": "7738400.0"
            }
          },
          {
            "code": "18201.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Anal fistula operations",
              "Readcode": "7738.11"
            }
          },
          {
            "code": "19419.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Insertion seton in high anal fistula+part lay open track HFQ",
              "Readcode": "7738300.0"
            }
          },
          {
            "code": "1979.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Anal fissure and fistula",
              "Readcode": "J53..00"
            }
          },
          {
            "code": "19952.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Ano-rectal fistula",
              "Readcode": "J531200"
            }
          },
          {
            "code": "20885.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Closure of rectal fistula",
              "Readcode": "7729700.0"
            }
          },
          {
            "code": "20959.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Laying open of high anal fistula",
              "Readcode": "7738100.0"
            }
          },
          {
            "code": "2406.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Laying open of anal fistula NEC",
              "Readcode": "7738200.0"
            }
          },
          {
            "code": "37729.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Fistula-in-ano NOS",
              "Readcode": "J531z00"
            }
          },
          {
            "code": "4791.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Excision of anal fistula",
              "Readcode": "7738611.0"
            }
          },
          {
            "code": "4994.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Laying open of low anal fistula",
              "Readcode": "7738000.0"
            }
          },
          {
            "code": "56271.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Sub-mucosal anal fistula",
              "Readcode": "J531000"
            }
          },
          {
            "code": "59127.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Inter-muscular anal fistula",
              "Readcode": "J531100"
            }
          },
          {
            "code": "598.0",
            "description": "Diagnosis of Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Fistula-in-ano",
              "Readcode": "J531.00"
            }
          },
          {
            "code": "7140.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Excision of fistula in ano",
              "Readcode": "7738600.0"
            }
          },
          {
            "code": "97573.0",
            "description": "Procedure for Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "ReadcodeDescr": "Repair of anal fistula using plug",
              "Readcode": "7738900.0"
            }
          }
        ]
      },
      {
        "concept_id": 967,
        "concept_version_id": 3073,
        "concept_name": "Anorectal fistula - Secondary care - Diagnoses",
        "coding_system": {
          "id": 4,
          "name": "ICD10 codes",
          "description": "ICD10 Codes"
        },
        "phenotype_id": "PH101",
        "phenotype_version_id": 202,
        "phenotype_name": "Anorectal fistula",
        "code_attribute_header": [
          "Disease",
          "Category"
        ],
        "codes": [
          {
            "code": "K60.3",
            "description": "Anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "K60.4",
            "description": "Rectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Diagnosis of Anorectal fistula"
            }
          },
          {
            "code": "K60.5",
            "description": "Anorectal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Diagnosis of Anorectal fistula"
            }
          }
        ]
      },
      {
        "concept_id": 968,
        "concept_version_id": 3075,
        "concept_name": "Anorectal fistula - Secondary care - Procedures",
        "coding_system": {
          "id": 7,
          "name": "OPCS4 codes",
          "description": "OPCS4 codes"
        },
        "phenotype_id": "PH101",
        "phenotype_version_id": 202,
        "phenotype_name": "Anorectal fistula",
        "code_attribute_header": [
          "Disease",
          "Category"
        ],
        "codes": [
          {
            "code": "H55.1",
            "description": "Laying open of low anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "H55.2",
            "description": "Laying open of high anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "H55.3",
            "description": "Laying open of anal fistula NEC",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "H55.4",
            "description": "Insertion of seton into high anal fistula and partial laying open of track HFQ",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "H55.5",
            "description": "Fistulography of anal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "H55.6",
            "description": "Probing of perineal fistula",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          },
          {
            "code": "H55.7",
            "description": "Repair of anal fistula using plug",
            "attributes": {
              "Disease": "Anorectal fistula",
              "Category": "Procedure for Anorectal fistula"
            }
          }
        ]
      }
    ],
    "status": 2,
    "doi": "https://doi.org/10.48533/nrc6-et83",
    "is_deleted": null,
    "publish_status": 2,
    "owner": "ieuan.scanlon",
    "template": {
      "id": 1,
      "name": "Clinical-Coded Phenotype",
      "description": "Phenotype definitions that are based on lists of clinical codes, or algorithms using clinical codes.",
      "version_id": 1
    },
    "versions": [
      {
        "version_id": 202,
        "version_name": "Anorectal fistula",
        "version_date": "2021-10-06T16:03:04.423014Z",
        "is_published": true,
        "is_latest": true
      }
    ]
  }
]