Vectorised function to calculate HLA mismatch levels where the HLA A, B and DR mismatch is recorded as a string rather than as separate numeric values, e.g. "1:0:1" or "101". The function calculates the mismatch level as used in the UK national deceased donor kidney matching scheme. By default, the function assumes a single separator character is used between each of the three numbers in the mismatch; if not, set the sep parameter to FALSE. This function needs the stringr package to be installed.
character string vector of HLA mismatches, e.g. "1:1:0" or "211"
logical to indicate whether separator used in the HLA mismatch strings (default TRUE)
The HLA mismatch level is derived from UK kidney matching policies which can be found on the NHS Blood & Transplant ODT website at www.odt.nhs.uk
numeric vector of HLA mismatch levels
1 2 3 4 5
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.