Skip to contents

computes Risk Index Combination for each pair donor-recipient

Usage

ric(
  DRI = "D1",
  data = candidates.uk,
  D1R1 = 1000,
  D1R2 = 700,
  D1R3 = 350,
  D1R4 = 0,
  D2R1 = 700,
  D2R2 = 1000,
  D2R3 = 500,
  D2R4 = 350,
  D3R1 = 350,
  D3R2 = 500,
  D3R3 = 1000,
  D3R4 = 700,
  D4R1 = 0,
  D4R2 = 350,
  D4R3 = 700,
  D4R4 = 1000,
  check.validity = TRUE
)

Arguments

DRI

Donor Risk Index group (D1, D2, D3, D4)

data

A data file with candidates information for UK transplant.

D1R1

A numeric value (0 - 1000) for the combination of indexes D1R1

D1R2

A numeric value (0 - 1000) for the combination of indexes D1R2

D1R3

A numeric value (0 - 1000) for the combination of indexes D1R3

D1R4

A numeric value (0 - 1000) for the combination of indexes D1R4

D2R1

A numeric value (0 - 1000) for the combination of indexes D2R1

D2R2

A numeric value (0 - 1000) for the combination of indexes D2R2

D2R3

A numeric value (0 - 1000) for the combination of indexes D2R3

D2R4

A numeric value (0 - 1000) for the combination of indexes D2R4

D3R1

A numeric value (0 - 1000) for the combination of indexes D3R1

D3R2

A numeric value (0 - 1000) for the combination of indexes D3R2

D3R3

A numeric value (0 - 1000) for the combination of indexes D3R3

D3R4

A numeric value (0 - 1000) for the combination of indexes D3R4

D4R1

A numeric value (0 - 1000) for the combination of indexes D4R1

D4R2

A numeric value (0 - 1000) for the combination of indexes D4R2

D4R3

A numeric value (0 - 1000) for the combination of indexes D4R3

D4R4

A numeric value (0 - 1000) for the combination of indexes D4R4

check.validity

Logical to decide whether to validate input.

Value

A table with a new column ric that gives the Risk Index Combination.

Examples

ric(DRI = 'D1', data = candidates.uk,
D1R1 = 1000, D1R2 = 700, D1R3 = 350, D1R4 = 0,
D2R1 = 700, D2R2 = 1000, D2R3 = 500, D2R4 = 350,
D3R1 = 350, D3R2 = 500, D3R3 = 1000, D3R4 = 700,
D4R1 = 0, D4R2 = 350, D4R3 = 700, D4R4 = 1000, check.validity = TRUE) %>% head()
#>   ID bg A1 A2 B1 B2 DR1 DR2 age dialysis cPRA Tier MS RRI urgent  ric
#> 1  1  A  2 24 15 44   1   4  53       59    0    B  3  R2      0  700
#> 2  2  O  1  2 57 58   4   7  41       35   16    B  5  R1      0 1000
#> 3  3  O 25 29 18 44   4   7  72       53    0    B  7  R3      0  350
#> 4  4  O  2 31 14 44   1  12  48       50    0    B  8  R2      0  700
#> 5  5  O  3 24  7 35   1  15  62       39    0    B  1  R2      0  700
#> 6  6  B 23 33 14 44   7   7  51       76    0    B  8  R3      0  350