this is the sdm1

dm_state_choice(
  recip_matrix = NULL,
  donor_matrix = NULL,
  allocation_score = NULL,
  HLA = NULL,
  graft_number = 1,
  parameter_state_a = 1,
  parameter_state_b = 1,
  parameter_state_c = 1,
  quality = TRUE,
  age = TRUE,
  bloodgroup = TRUE,
  accept_prob = NULL,
  yearly_scale = rep(1, 100)
)

Arguments

recip_matrix

a data.frame with recipient features, this is the input recipient matrix

donor_matrix

a data.frame with donor features, this is the input donor matrix

allocation_score

a vector, this is the score for each pair

HLA

a matrix, this is the calculated HLA mismatching counts matrix

graft_number

a numerical value, this is the graft number

parameter_state_a

an interger hyperparameter to tune

parameter_state_b

an interger hyperparameter to tune

parameter_state_c

an interger hyperparameter to tune

quality

a boolean value, TRUE/FALSE, quality measure indicator

age

a boolean value, TRUE/FALSE, age indicator

bloodgroup

a boolean value, TRUE/FALSE, blood group indicator

accept_prob

a numerical value between 0 and 1, acceptence probability

yearly_scale

a vector representing yearly scale

Value

matched recipient

a data.frame with matched recipient

Examples

data("newdata", package = "simKAP") HLA_matrix <- hla_match(raw_recip_matrix_subset, raw_donor_matrix[1,]) selected <- dm_state_choice(raw_recip_matrix_subset,raw_donor_matrix[1,], allocation_score=allocation_national(raw_recip_matrix_subset,raw_donor_matrix[1,],HLA_matrix), HLA_matrix,1,1,1,1,TRUE,TRUE,TRUE,accept_prob = NULL, yearly_scale=rep(1, 100));
#> [1] "State"
#> Warning: no non-missing arguments to min; returning Inf